-
code for Allow Insert Hyperlink
Hi All,
Please help me with the VBA to Allow Insert Hyperlinks from an unlocked cell
in a protected sheet.
The worksheet is protected and all cells are unlocked. It has code to lock
rows as a Final cell is changed to Yes. I also have code in ThisWorkbook that
hides columns based on current user. What happens is, in the course of
opening the file, the Allow Insert Hyperlinks is set to not checked,
regardless of its status when the file is saved. So I need to add code to set
Allow Insert Hyperlink to Yes. To make it clearer, below is the process:
ThisWorkbook
>gets current user
>unprotects worksheet
>unhides all columns
>hides columns (based on current user)
>>>needs to set Allow Insert Hyperlinks<<<
>protects sheet
Thanks for any help.
Jeff -
RE: code for Allow Insert Hyperlink
This code will protect the activesheet and allow inserting of hyperlinks.
ActiveSheet.Protect Password:= "password", AllowInsertingHyperlinks:=True
If you want to test if AllowInsertingHyperlinks is true run this code.
If ActiveSheet.Protection.AllowInsertingHyperlinks = True Then
Msgbox "AllowInsertingHyperlinks = True"
End If
Read the VBA help on "Allow Hyperlinks". Hope this helps! If so, let me
know, click "YES" below.
--
Cheers,
Ryan
"Jeff" wrote:
> Hi All,
> Please help me with the VBA to Allow Insert Hyperlinks from an unlocked cell
> in a protected sheet.
>
> The worksheet is protected and all cells are unlocked. It has code to lock
> rows as a Final cell is changed to Yes. I also have code in ThisWorkbook that
> hides columns based on current user. What happens is, in the course of
> opening the file, the Allow Insert Hyperlinks is set to not checked,
> regardless of its status when the file is saved. So I need to add code to set
> Allow Insert Hyperlink to Yes. To make it clearer, below is the process:
> ThisWorkbook
> >gets current user
> >unprotects worksheet
> >unhides all columns
> >hides columns (based on current user)
> >>>needs to set Allow Insert Hyperlinks<<<
> >protects sheet
> Thanks for any help.
> Jeff -
RE: code for Allow Insert Hyperlink
Super, Ryan. Thank you.
"Ryan H" wrote:
> This code will protect the activesheet and allow inserting of hyperlinks.
>
> ActiveSheet.Protect Password:= "password", AllowInsertingHyperlinks:=True
>
> If you want to test if AllowInsertingHyperlinks is true run this code.
>
> If ActiveSheet.Protection.AllowInsertingHyperlinks = True Then
> Msgbox "AllowInsertingHyperlinks = True"
> End If
>
> Read the VBA help on "Allow Hyperlinks". Hope this helps! If so, let me
> know, click "YES" below.
>
> --
> Cheers,
> Ryan
>
>
> "Jeff" wrote:
>
> > Hi All,
> > Please help me with the VBA to Allow Insert Hyperlinks from an unlocked cell
> > in a protected sheet.
> >
> > The worksheet is protected and all cells are unlocked. It has code to lock
> > rows as a Final cell is changed to Yes. I also have code in ThisWorkbook that
> > hides columns based on current user. What happens is, in the course of
> > opening the file, the Allow Insert Hyperlinks is set to not checked,
> > regardless of its status when the file is saved. So I need to add code to set
> > Allow Insert Hyperlink to Yes. To make it clearer, below is the process:
> > ThisWorkbook
> > >gets current user
> > >unprotects worksheet
> > >unhides all columns
> > >hides columns (based on current user)
> > >>>needs to set Allow Insert Hyperlinks<<<
> > >protects sheet
> > Thanks for any help.
> > Jeff Similar Threads -
By Brant in forum Access Forms
Replies: 1
Last Post: 03-30-2009, 07:00 PM -
By Nigel in forum Programming (VBA, VB, C# etc)
Replies: 4
Last Post: 01-25-2009, 06:32 AM -
By Todd Huttenstine in forum Programming (VBA, VB, C# etc)
Replies: 1
Last Post: 01-21-2009, 03:47 AM -
By Todd Huttenstine in forum Programming (VBA, VB, C# etc)
Replies: 1
Last Post: 01-21-2009, 03:33 AM -
By Lucas in forum Access Forms
Replies: 1
Last Post: 01-17-2009, 12:44 PM Posting Permissions - You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Bookmarks