C
clayton
Hello, I want to be able to unprotect my sheet, add a wordart graphi
and reprotect my sheet. The problem I am having is when I do this wit
code the file is protected with the default parameters selected. I wan
to be able to enable wordart so I can insert a wordart object and the
protect the sheet again.
I want to get around the user being able to just delect the added wor
art.
When protected I would like the following parameters to be set:
Allow users to
select locked cells
select Unlocked cells
format cells
format rows
Its the "edit objects" parameter that needs to be enabled for me to ad
a wordart object.
This is what I have so far.
Private Sub CommandButton3_Click()
response = MsgBox("This document will be stamped COPY. ", _
vbYesNo)
If response = vbYes Then
Set myDocument = ActiveSheet
Set myWatermark = myDocument.Shapes.AddTextEffect( _
PresetTextEffect:=msoTextEffect1, _
text:="Draft", _
FontName:="Arial Black", _
FontSize:=100, _
FontBold:=False, _
FontItalic:=False, _
Left:=218.75, _
Top:=159.75)
With myWatermark
.IncrementRotation -43.46
.Fill.Visible = msoFalse
.Fill.Transparency = 0.5
.Line.Weight = 0.75
.Line.DashStyle = msoLineSolid
.Line.Style = msoLineSingle
.Line.Transparency = 0#
.Line.Visible = msoTrue
.Line.ForeColor.SchemeColor = 55
.Line.BackColor.RGB = RGB(255, 255, 255)
.ZOrder msoBringToFront
End With
Dim strClient As String
'Dim csPATH As String
strClient = Application.InputBox("Enter your file name")
Const csPATH As String = "c:\"
ActiveWorkbook.SaveCopyAs csPATH & Trim(strClient) & " PO For
Copy.xls"
MsgBox strClient & " PO Form Copy.xls has been saved to C:\"
ElseIf vbNo Then
Exit Sub
End If
Also, is there a way to have it prompt the user for a path? Like
browse button so they can save it where they would like?
Thanks for ANY help
and reprotect my sheet. The problem I am having is when I do this wit
code the file is protected with the default parameters selected. I wan
to be able to enable wordart so I can insert a wordart object and the
protect the sheet again.
I want to get around the user being able to just delect the added wor
art.
When protected I would like the following parameters to be set:
Allow users to
select locked cells
select Unlocked cells
format cells
format rows
Its the "edit objects" parameter that needs to be enabled for me to ad
a wordart object.
This is what I have so far.
Private Sub CommandButton3_Click()
response = MsgBox("This document will be stamped COPY. ", _
vbYesNo)
If response = vbYes Then
Set myDocument = ActiveSheet
Set myWatermark = myDocument.Shapes.AddTextEffect( _
PresetTextEffect:=msoTextEffect1, _
text:="Draft", _
FontName:="Arial Black", _
FontSize:=100, _
FontBold:=False, _
FontItalic:=False, _
Left:=218.75, _
Top:=159.75)
With myWatermark
.IncrementRotation -43.46
.Fill.Visible = msoFalse
.Fill.Transparency = 0.5
.Line.Weight = 0.75
.Line.DashStyle = msoLineSolid
.Line.Style = msoLineSingle
.Line.Transparency = 0#
.Line.Visible = msoTrue
.Line.ForeColor.SchemeColor = 55
.Line.BackColor.RGB = RGB(255, 255, 255)
.ZOrder msoBringToFront
End With
Dim strClient As String
'Dim csPATH As String
strClient = Application.InputBox("Enter your file name")
Const csPATH As String = "c:\"
ActiveWorkbook.SaveCopyAs csPATH & Trim(strClient) & " PO For
Copy.xls"
MsgBox strClient & " PO Form Copy.xls has been saved to C:\"
ElseIf vbNo Then
Exit Sub
End If
Also, is there a way to have it prompt the user for a path? Like
browse button so they can save it where they would like?
Thanks for ANY help