View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bernard Liengme[_3_] Bernard Liengme[_3_] is offline
external usenet poster
 
Posts: 1,104
Default Formula to use date in file name link reference

You need to use the INDIRECT function
=SUM(INDIRECT("'G:\PATH
HERE\Poker\["&TEXT(D2,"ddmmyy")&".xls]POKER'!$H$16:$H$21"))

Your example date (02/01/2009) gave no clue as your date convention. My
formula is for the universal format dd/mm/yyyy; for the USA format please
change to TEXT(D2,"mmddyy")

best wishes
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email

"DFruge" wrote in message
...
I am stuck with this one and was hoping someone could help. I am
trying to figure out a formula that uses the date from a cell in the
file reference.
D2 contains: 02/01/09 (date format)
D7 contains the current formula:=SUM('G:\PATH HERE\Poker\[020109.xls]
POKER'!$H$16:$H$21)
I want the date portion of the formula "020109" to be replaced with
the date in D2. Each column has a different date. Any help anyone
can provide is greatly appreciated.