View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Jim Rech Jim Rech is offline
external usenet poster
 
Posts: 2,718
Default Set to Read Only

If you mean that you want to open a workbook and then change it to
read-only, you can do it like this:

On Error Resume Next
ActiveWorkbook.Saved = True
ActiveWorkbook.ChangeFileAccess Mode:=xlReadOnly

The On Error is in case the workbook is already RO.

--
Jim Rech
Excel MVP