Disable 'Update Links' message when opening workbook

  • We receive a lot of spreadsheets from our clients that contain links to their internal servers. Obviously we can not update these links and we get the following error:


    Code
    "This workbook contains one or more links that cannot be updated"


    I'm trying to run some VBA on these as they come in and I'm having a few problems. This being one of them.


    Is it possible to disable all linking with VBA or maybe another way so it doesn't interrupt the script?


    Andy.

  • Re: Links to other spredsheets.



    I'
    the error is where I've highlighted in bold. "argument not optional" is what I get. I've tried putting set = before but the error is the same. Also I'm not 100% its in the right place. I don't know if its obvious but I'm no VBA expert haha.

  • Re: Links to other spredsheets.


    Bold tags don't work inside code tags...


    Code
    Set wb = Workbooks.Open(FileName:=Pathname & Filename, UpdateLinks:=False)


    Your other Open statement is redundant

  • Re: Disable 'Update Links' message when opening workbook


    That makes sense. Also thanks for pointing me to the workbook commands, it helps me to get a better understanding and now I see how to use these commands better.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!