Open a read only file as a writable file

G

Guest

I have a file that is marked as recommended read only. I would like to have
my macro open the file alter it and save it but I can't seem to automatically
get rid of the message box when I open the file that asks if you would like
it to be read only.

I have tried
workbooks.open(file,,false)

And I have tried
Application.DisplayAlerts = False
workbooks.open(file)
Application.DisplayAlerts = True

The first method did nothing and the second method opened it as a read only
file.

Any suggestions?
 
J

Jim Rech

Workbooks.Open Filename:="C:\book1.xls", IgnoreReadOnlyRecommended:=True

--
Jim
|I have a file that is marked as recommended read only. I would like to have
| my macro open the file alter it and save it but I can't seem to
automatically
| get rid of the message box when I open the file that asks if you would
like
| it to be read only.
|
| I have tried
| workbooks.open(file,,false)
|
| And I have tried
| Application.DisplayAlerts = False
| workbooks.open(file)
| Application.DisplayAlerts = True
|
| The first method did nothing and the second method opened it as a read
only
| file.
|
| Any suggestions?
|
 

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