Workbook.Open Question

G

Guest

I've been having some intermittent failures in a macro I'm running. I just
realized that I had

Set oWB = Workbooks.Open(sFile)

Instead of

Set oWB = Workbooks.Open(sFile, UpdateLinks = False, ReadOnly = True)

Could that be causing my problem if someone else is using the file?

Thanks,
Barb Reinhardt
 
G

Guest

Set oWB = Workbooks.Open(sFile, UpdateLinks = False, ReadOnly = True)
should be

Set oWB = Workbooks.Open(sFile, UpdateLinks:= False, ReadOnly:=True)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top