mike p
06-18-2010, 12:40 PM
Working on a script that puts a subset of data from a large excel database workbook into a smaller version of the same (strips some of the data). I am using
Set objWorkbook = objExcel.Workbooks.Open(FileName)
to open the workbook. The parent workbook is password protected and I would like to open as read only and I am having some trouble figuring out the proper form this statement should take to enable opening in that mode. (Don't want to have to click the read only button on the pop-up). I have tried adding ",readOnly:=TRUE" into the open statement but it returns an error (says it expects a ")").
Any thoughts are appreciated. This in Office 2007 BTW.
Thanks,
Mike
Set objWorkbook = objExcel.Workbooks.Open(FileName)
to open the workbook. The parent workbook is password protected and I would like to open as read only and I am having some trouble figuring out the proper form this statement should take to enable opening in that mode. (Don't want to have to click the read only button on the pop-up). I have tried adding ",readOnly:=TRUE" into the open statement but it returns an error (says it expects a ")").
Any thoughts are appreciated. This in Office 2007 BTW.
Thanks,
Mike