LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,560
Default Resetting Hyperlink to Worksheet

I have a program that renames the names in Column A and its associated
worksheet.
All the names in Column A are hyperlinked to its associated worksheet. The
names in Column A and the worksheet name are the same.
When I make the name changes, the hyperlink is broken.
I just need to set the hyperlink in the cell that was changed in Column A to
it's associated worksheet again.

Here is the code I use to make the changes. Thanks!

RowNum = Application.InputBox(prompt:="What is the Row Number of the
Location You Want to Change?", Type:=2)
FranNum = Application.InputBox(prompt:="What is the Franchise Number You
Want to Use?", Type:=2)
LabelName = Application.InputBox(prompt:="What is the Franchise Name You
Want To Use?", Type:=2)

If RowNum = "0" Then
'do nothing
Else

Cells((RowNum), 1).Select
OldLabelName = Cells((RowNum), 1).Value

Cells((RowNum), 2).Select

ActiveCell.FormulaR1C1 = (FranNum)
Cells((RowNum), 1).Select
ActiveCell.FormulaR1C1 = (LabelName)
Cells((RowNum), 1).Select
Selection.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
Sheets(OldLabelName).Select
Sheets(OldLabelName).Name = (LabelName)

NEED CODE HERE TO RESET THE HYPERLINK TO THE SHEET ONLY - NOT TO A CELL ON
THE SHEET.

David


 
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
Chart worksheet names keep resetting dloomer Charts and Charting in Excel 0 December 10th 09 05:58 PM
Hyperlink - particular worksheet Mike Excel Discussion (Misc queries) 0 May 11th 09 09:28 PM
Troubleshoot resetting hyperlink base to a network drive Diane Excel Worksheet Functions 1 August 12th 05 05:38 PM
Resetting the end of a worksheet Cachod1 New Users to Excel 1 March 29th 05 07:44 PM
resetting worksheet properties Michael J. Malinsky Excel Programming 1 July 15th 03 05:23 PM


All times are GMT +1. The time now is 02:07 AM.

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

About Us

"It's about Microsoft Excel"