Not quite sure where did you get the following statement:
Application "C:\EMS-Senior1\Individual Report Class1.doc"
-- the purpose is to open the file, right?
Try to replace it with this one and re-run your code:
Shell "WinWord C:\EMS-Senior1\Individual Report Class1.doc"
It worked in my PC!
--
Best regards,
---
Yongjun CHEN
=================================
XLDataSoft - Data Analysis Expert, Excel/VBA Specialist
- - - -
www.XLDataSoft.com - - - -
Free Excel-Based Data Processing Tool is Available for Download
=================================
"Param" <(E-Mail Removed)> wrote in message
news:B0C5F7B4-F33C-438F-8DF6-(E-Mail Removed)...
> Pls correct me on this formula: something wrong on opening file.
>
> Sub openreport()
> myPWD = Application.InputBox("Password Protected! Please Enter Authorized
> Password to Continue!")
> If myPWD = "ems5657sifooc1" Then
> Application "C:\EMS-Senior1\Individual Report Class1.doc"
> Else
> MsgBox "Wrong Password! Bye!"
> End If
> For Each w In Workbooks
> w.Save
> Next
> Application.quit
> End Sub
>