Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,355
Default Creating a Hyperlink from 1 WKBK to open another WKBK and activate

I would like to be able to click a hyperlink within an excel workbook and
that would allow me to open another workbook and activate a worksheet within
that. Is this possible to do with a hyperlink, or would i need to create
another procedure to do this? I'm thinking maybe of using a selection change
event and if I select a cell that has what I'd want for a "hyperlink" it
would open the appropriate workbook/worksheet combo. Comments?

Thanks,
Barb Reinhardt
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Creating a Hyperlink from 1 WKBK to open another WKBK and activate

=HYPERLINK("file:///C:\Documents and
Settings\User\Desktop\Book2.xls#Sheet2!B9")


will jump to Book2.xls. If Book2 is not open, Excel will open it.
--
Gary''s Student - gsnu200726


"Barb Reinhardt" wrote:

I would like to be able to click a hyperlink within an excel workbook and
that would allow me to open another workbook and activate a worksheet within
that. Is this possible to do with a hyperlink, or would i need to create
another procedure to do this? I'm thinking maybe of using a selection change
event and if I select a cell that has what I'd want for a "hyperlink" it
would open the appropriate workbook/worksheet combo. Comments?

Thanks,
Barb Reinhardt

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,355
Default Creating a Hyperlink from 1 WKBK to open another WKBK and acti

Thanks. What does the file:/// part do?

"Gary''s Student" wrote:

=HYPERLINK("file:///C:\Documents and
Settings\User\Desktop\Book2.xls#Sheet2!B9")


will jump to Book2.xls. If Book2 is not open, Excel will open it.
--
Gary''s Student - gsnu200726


"Barb Reinhardt" wrote:

I would like to be able to click a hyperlink within an excel workbook and
that would allow me to open another workbook and activate a worksheet within
that. Is this possible to do with a hyperlink, or would i need to create
another procedure to do this? I'm thinking maybe of using a selection change
event and if I select a cell that has what I'd want for a "hyperlink" it
would open the appropriate workbook/worksheet combo. Comments?

Thanks,
Barb Reinhardt

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Creating a Hyperlink from 1 WKBK to open another WKBK and acti

Some hyperlink apps need to know if the destination is a file or a website.
Other apps don't care. I use this form out of habit
--
Gary''s Student - gsnu200726


"Barb Reinhardt" wrote:

Thanks. What does the file:/// part do?

"Gary''s Student" wrote:

=HYPERLINK("file:///C:\Documents and
Settings\User\Desktop\Book2.xls#Sheet2!B9")


will jump to Book2.xls. If Book2 is not open, Excel will open it.
--
Gary''s Student - gsnu200726


"Barb Reinhardt" wrote:

I would like to be able to click a hyperlink within an excel workbook and
that would allow me to open another workbook and activate a worksheet within
that. Is this possible to do with a hyperlink, or would i need to create
another procedure to do this? I'm thinking maybe of using a selection change
event and if I select a cell that has what I'd want for a "hyperlink" it
would open the appropriate workbook/worksheet combo. Comments?

Thanks,
Barb Reinhardt

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,355
Default Creating a Hyperlink from 1 WKBK to open another WKBK and acti

I'm getting a reference not valid error. This is the filepath I have

\\SERVER\FOLDER\Folder\WBName.xls#WSName!A1

I opted to create it this way
aWS.Hyperlinks.Add anchor:=aWS.Cells(lRow, WSName.Column), _
Address:="file:///" & oWB.Path & "/" & oWB.name & "#" & oWS.name &
"!A1", _
TextToDisplay:=oWS.name

What am I missing?

Thanks
Barb Reinhardt
"Gary''s Student" wrote:

Some hyperlink apps need to know if the destination is a file or a website.
Other apps don't care. I use this form out of habit
--
Gary''s Student - gsnu200726


"Barb Reinhardt" wrote:

Thanks. What does the file:/// part do?

"Gary''s Student" wrote:

=HYPERLINK("file:///C:\Documents and
Settings\User\Desktop\Book2.xls#Sheet2!B9")


will jump to Book2.xls. If Book2 is not open, Excel will open it.
--
Gary''s Student - gsnu200726


"Barb Reinhardt" wrote:

I would like to be able to click a hyperlink within an excel workbook and
that would allow me to open another workbook and activate a worksheet within
that. Is this possible to do with a hyperlink, or would i need to create
another procedure to do this? I'm thinking maybe of using a selection change
event and if I select a cell that has what I'd want for a "hyperlink" it
would open the appropriate workbook/worksheet combo. Comments?

Thanks,
Barb Reinhardt



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Creating a Hyperlink from 1 WKBK to open another WKBK and acti

Visually, does the cell look like:
file:///\\SERVER\FOLDER\Folder\WBName.xls#WSName!A1

especially important is the:
///\\
--
Gary''s Student - gsnu200726


"Barb Reinhardt" wrote:

I'm getting a reference not valid error. This is the filepath I have

\\SERVER\FOLDER\Folder\WBName.xls#WSName!A1

I opted to create it this way
aWS.Hyperlinks.Add anchor:=aWS.Cells(lRow, WSName.Column), _
Address:="file:///" & oWB.Path & "/" & oWB.name & "#" & oWS.name &
"!A1", _
TextToDisplay:=oWS.name

What am I missing?

Thanks
Barb Reinhardt
"Gary''s Student" wrote:

Some hyperlink apps need to know if the destination is a file or a website.
Other apps don't care. I use this form out of habit
--
Gary''s Student - gsnu200726


"Barb Reinhardt" wrote:

Thanks. What does the file:/// part do?

"Gary''s Student" wrote:

=HYPERLINK("file:///C:\Documents and
Settings\User\Desktop\Book2.xls#Sheet2!B9")


will jump to Book2.xls. If Book2 is not open, Excel will open it.
--
Gary''s Student - gsnu200726


"Barb Reinhardt" wrote:

I would like to be able to click a hyperlink within an excel workbook and
that would allow me to open another workbook and activate a worksheet within
that. Is this possible to do with a hyperlink, or would i need to create
another procedure to do this? I'm thinking maybe of using a selection change
event and if I select a cell that has what I'd want for a "hyperlink" it
would open the appropriate workbook/worksheet combo. Comments?

Thanks,
Barb Reinhardt

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
Sumif Error when Referenced Wkbk not open Maverick_TG Excel Discussion (Misc queries) 1 April 17th 08 06:28 PM
run a procedure in 1 wkbk from another wkbk carenla Excel Programming 1 July 7th 05 05:40 PM
Keep original wkbk open after SaveAs? Ed Excel Programming 2 May 2nd 05 10:12 PM
Open Object as Wkbk opens Myriam Excel Programming 0 April 6th 05 04:07 PM
Error Message Wkbk Open Tom Ulincy[_2_] Excel Programming 1 August 6th 03 04:12 PM


All times are GMT +1. The time now is 04:49 PM.

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"