View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
casey casey is offline
external usenet poster
 
Posts: 3
Default Question on formula

I have an Access DB with VBA coding that transfers the data to Excel. With
it is a formula:

xlObj.Application.ActiveCell.FormulaR1C1 = "='" & pubXLFolder &
"[file.xls]sheet1'!R4C3"
pubXLFolder = "\\sales\reports\

The above code is referencing the value from another spreadsheet on the
network.

But I noticed when copying the file to my local drive, instead of seeing the
cell reference as:
\\sales\reports\[file.xls]sheet1'$C$4 it shows as
c:\db\[file.xls]sheet1'$C$4
This will cause a problem, since the excel file will eventually be posted on
the company intranet website. So, when users open the file and asks for
update, the network reference should kick in.

Do i need to incorporate a refresh link on my code? Pls help!