View Single Post
  #6   Report Post  
Eric
 
Posts: n/a
Default

Bob,

Thank you for your information. I copied the code and pasted it into the
view code area, and it still does not work. I can open the file, type
anything in it and still it allows me to save it with what I have typed in.
Do I need to change any of the code after I paste it? I do GREATLY
appreciate your help!!

Eric


"Bob Phillips" wrote:

Eric,

You could force a save on open

Private Sub Workbook_Open()
Dim sFilename
sFilename = Application.GetSaveAsFilename( _
fileFilter:="Excel Files (*.xls), *.xls")
If sFilename < False Then
ThisWorkbook.SaveAs sFilename
Else
ThisWorkbook.Close False
End If
End If

End Sub

'This is workbook event code.
'To input this code, right click on the Excel icon on the worksheet
'(or next to the File menu if you maximise your workbooks),
'select View Code from the menu, and paste the code



--

HTH

RP
(remove nothere from the email address if mailing direct)


"Eric" wrote in message
...
I have an excel spreadsheet on a shared drive at work. When people in the
office open the file, is there a way to make them "save as" and not to be
able to type on the original file?

Thanks for any help in advance!!!

Eric