ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Filepath and Updating Links (https://www.excelbanter.com/excel-programming/320289-filepath-updating-links.html)

StephanieH

Filepath and Updating Links
 
This is probably really simple and I'm just missing it, but need something
that will tell Excel that if I'm opening a file in the file folder "Loan
Recovery MIS" or if the file path name begins with
"\\Fl-aejf-fs1\Data\Data\RECOVERY\EXLDATA\Loan Recovery MIS" then do not
update the links.

I've tried

If filepath = "\\Fl-aejf-fs1\Data\Data\RECOVERY\EXLDATA\Loan Recovery MIS" _
Then UpdateLinks:=0

But I get "Expected = Expression" with the := highlighted.


Sharad Naik

Filepath and Updating Links
 
You are not refering to a workbook at all.
Then it is not Links but Link
And it is not filepath but .Path

Something like below -

If ThisWorkbook.Path = "\\Fl-aejf-fs1\Data\Data\RECOVERY\EXLDATA\Loan
Recovery MIS" _
Then ThisWorkbook.UpdateLink:=False

(you can of course shorten a bit using With statement)

Tell us how exactly you are opening the workbook (I presume that you are
opening it through VBA),
and we can tell you how to do it.

Sharad

"StephanieH" wrote in message
...
This is probably really simple and I'm just missing it, but need something
that will tell Excel that if I'm opening a file in the file folder "Loan
Recovery MIS" or if the file path name begins with
"\\Fl-aejf-fs1\Data\Data\RECOVERY\EXLDATA\Loan Recovery MIS" then do not
update the links.

I've tried

If filepath = "\\Fl-aejf-fs1\Data\Data\RECOVERY\EXLDATA\Loan Recovery MIS"
_
Then UpdateLinks:=0

But I get "Expected = Expression" with the := highlighted.




StephanieH

Filepath and Updating Links
 
I open a main file using VBA (there's other stuff built in of course, but
here's that line)
Workbooks.Open Filename:="\\Fl-aejf-fs1\Data\Data\RECOVERY\EXLDATA\Loan
Recovery MIS\" & MyValue & "\Gross Placement Batch Tracks\Summary Data\" &
ListBox1.List(i) & " GBT Summary " & MyValue & ".xls"

But from there, I have several hyperlinks to other files in the Loan
Recovery MIS folder. When they are access from the hyperlink, they will
automatically prompt the user to update the links. I don't think it can be
surpressed the hyperlink, so I was hoping to use a macro to automatically
tell it to not update any file in Loan Recovery MIS upon opening.



"Sharad Naik" wrote:

You are not refering to a workbook at all.
Then it is not Links but Link
And it is not filepath but .Path

Something like below -

If ThisWorkbook.Path = "\\Fl-aejf-fs1\Data\Data\RECOVERY\EXLDATA\Loan
Recovery MIS" _
Then ThisWorkbook.UpdateLink:=False

(you can of course shorten a bit using With statement)

Tell us how exactly you are opening the workbook (I presume that you are
opening it through VBA),
and we can tell you how to do it.

Sharad

"StephanieH" wrote in message
...
This is probably really simple and I'm just missing it, but need something
that will tell Excel that if I'm opening a file in the file folder "Loan
Recovery MIS" or if the file path name begins with
"\\Fl-aejf-fs1\Data\Data\RECOVERY\EXLDATA\Loan Recovery MIS" then do not
update the links.

I've tried

If filepath = "\\Fl-aejf-fs1\Data\Data\RECOVERY\EXLDATA\Loan Recovery MIS"
_
Then UpdateLinks:=0

But I get "Expected = Expression" with the := highlighted.






All times are GMT +1. The time now is 02:14 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com