Results 1 to 2 of 2
  1. #1
    New Lounger
    Join Date
    Nov 2004
    Sacramento, California, USA
    Thanked 0 Times in 0 Posts

    Open without Read Only (Excel 2000)

    I have a macro that opens files set to read only. The purposes of the Macro is to Password Protect the selected files. However, I have set up the macro with these statements:

    Application.DisplayAlerts = False
    Workbooks.Open Filename:=FilesToOpen(x), ReadOnly:=False
    ActiveWorkbook.SaveAs Filename:=FilesToOpen(x), _
    FileFormat:=xlNormal, Password:=sPwd, WriteResPassword:="", ReadOnlyRecommended:=False, CreateBackup:=False
    I thought I would be opening WITHOUT Read Only and Saving WITHOUT ReadOnly - but, the file opens as read only.

    Any options to allow the files to be password protected?

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Thanked 31 Times in 31 Posts

    Re: Open without Read Only (Excel 2000)

    If a workbook has been saved with Read Only Recommended on, opening it will display the warning dialog even if you open it with ReadOnly:=False. The line Application.DisplayAlerts = False suppresses the warning dialog and supplies the default reply (open as read-only)

    In Excel 2002, you can use

    Workbooks.Open Filename:=FilesToOpen(x), ReadOnly:=False, IgnoreReadOnlyRecommended:=True

    Does that work in Excel 2000?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts