Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,670
Default How to add a variable as a parameter for a link?

Will it be possible to add a variable as a parameter for the link? as shown
below format, therefore, I can change its parameter based on certain cell
value to link different spreadsheets? for example

Original
'[filename.xls]6220.HK'!$E$2

Modified approach
'[filename.xls]C2.HK'!$E$2 , where C2 = 6220, which equals to linking
'[filename.xls]6220.HK'!$E$2

Thank for any suggestion
Eric

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default How to add a variable as a parameter for a link?

You'd want to use the =indirect() function, but that only works when the
"sending" workbook is open.

But Harlan Grove wrote a UDF called PULL that will retrieve the value from a
closed workbook.

You can find the function at Harlan's FTP site:
ftp://members.aol.com/hrlngrv/
Look for pull.zip

Laurent Longre has an addin (morefunc.xll) at:
http://xcell05.free.fr/

That includes =indirect.ext() that may help you.

Eric wrote:

Will it be possible to add a variable as a parameter for the link? as shown
below format, therefore, I can change its parameter based on certain cell
value to link different spreadsheets? for example

Original
'[filename.xls]6220.HK'!$E$2

Modified approach
'[filename.xls]C2.HK'!$E$2 , where C2 = 6220, which equals to linking
'[filename.xls]6220.HK'!$E$2

Thank for any suggestion
Eric


--

Dave Peterson
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
Aling multiple sets of data by header column MarkusO Excel Discussion (Misc queries) 2 April 12th 06 07:29 PM
How do I link to a workbook whose name is variable? Carl Borthwick Excel Discussion (Misc queries) 1 January 13th 06 10:01 AM
Create an external reference link with embedded variable Greentree Excel Worksheet Functions 1 October 9th 05 07:46 PM
variable in a link where the variable is the name of the sheet darrelly Excel Worksheet Functions 1 October 7th 05 08:24 AM
Variable Link to Workbooks dfrancefort Excel Worksheet Functions 1 April 28th 05 01:15 AM


All times are GMT +1. The time now is 02:35 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"