Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 99
Default Hyperlink Back w/ locked worksheet

I have a large file with dozens of worksheets. With the help of the community
I was able to find a simple macro that would help a user hyperlink back to
the origin using the following code (I have back buttons scattered
throughout):

Sub goback()
Application.Goto
End Sub

Here is the problem: 4 of my worksheets are locked WITHOUT allowing the user
to select cells (has to be that way because of a number of macros that run on
that page and input is all radio buttons...long story).

How can I use the above code to go back on a page that is protected from
selecting locked cells? I tried to add an unlock procedure, something like:

Sub goback()
..Unprotect Password:="test"
Application.Goto
..Protect Password:="test"
End Sub

BUT with no luck. Help would be much appreciated!! Thanks.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Hyperlink Back w/ locked worksheet

You need to unprotect the destination worksheet. Since it might be any of
the 4 protected sheets, consider:

1. unprotect all 4 protected sheets
2. do the goto
3. re-protect all 4 sheets

This way you do not have to determine if your destination is protected or not.
--
Gary''s Student - gsnu200859


"dgold82" wrote:

I have a large file with dozens of worksheets. With the help of the community
I was able to find a simple macro that would help a user hyperlink back to
the origin using the following code (I have back buttons scattered
throughout):

Sub goback()
Application.Goto
End Sub

Here is the problem: 4 of my worksheets are locked WITHOUT allowing the user
to select cells (has to be that way because of a number of macros that run on
that page and input is all radio buttons...long story).

How can I use the above code to go back on a page that is protected from
selecting locked cells? I tried to add an unlock procedure, something like:

Sub goback()
.Unprotect Password:="test"
Application.Goto
.Protect Password:="test"
End Sub

BUT with no luck. Help would be much appreciated!! Thanks.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 99
Default Hyperlink Back w/ locked worksheet

Thanks, Gary. That is what I was thinking but I couldn't figure out how to
manipulate the macro to do that. What am I doing wrong below?

"Gary''s Student" wrote:

You need to unprotect the destination worksheet. Since it might be any of
the 4 protected sheets, consider:

1. unprotect all 4 protected sheets
2. do the goto
3. re-protect all 4 sheets

This way you do not have to determine if your destination is protected or not.
--
Gary''s Student - gsnu200859


"dgold82" wrote:

I have a large file with dozens of worksheets. With the help of the community
I was able to find a simple macro that would help a user hyperlink back to
the origin using the following code (I have back buttons scattered
throughout):

Sub goback()
Application.Goto
End Sub

Here is the problem: 4 of my worksheets are locked WITHOUT allowing the user
to select cells (has to be that way because of a number of macros that run on
that page and input is all radio buttons...long story).

How can I use the above code to go back on a page that is protected from
selecting locked cells? I tried to add an unlock procedure, something like:

Sub goback()
.Unprotect Password:="test"
Application.Goto
.Protect Password:="test"
End Sub

BUT with no luck. Help would be much appreciated!! Thanks.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Locked worksheet & hyperlinks (w/ select locked cells unchecked) dgold82 Excel Discussion (Misc queries) 1 July 10th 09 09:42 PM
Hyperlink Back Hyperlinking Back Excel Programming 9 July 9th 09 05:11 PM
Back door into locked form XP Excel Programming 5 July 31st 07 04:43 PM
how do i go back from a hyperlink ? Ed lee Excel Discussion (Misc queries) 1 January 17th 07 05:19 PM
hyperlink: back to last worksheet my Excel Worksheet Functions 1 August 9th 06 08:25 PM


All times are GMT +1. The time now is 12:01 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"