I have the following script that I want to use to save an excel workbook as a pdf and email it through Outlook. I have this file on my computer and the script works perfectly. As soon as I send the file to someone else, it doesn't work. Throws a Runtime 1004 error. I will color the area of the script that it shows wrong when hitting the debug button red.

Script:


Sub EmailPDF()
fdir = "c:\\temp\\"
fname = InputBox("Please Enter Filename")
fpath = fdir & fname & ".pdf"
With Application
.EnableEvents = True
.ScreenUpdating = False
End With

ToAddress = "email@domain.com"
CCAddress = Range("C1")
CCAddress2 = Range("i10")
CCAddress3 = CCAddress & "; " & CCAddress2
MailSub = "Order " & fname

'Generate PDF document to c:\. Substitute ActiveSheet for ActiveWorkbook to PDF the entire document
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, FileName:= _
fpath, Quality:=xlQualityStandard, _
IncludeDocProperties:=False, IgnorePrintAreas:=False, OpenAfterPublish:=False



'Create Mail & attach PDF
Set oOutlookApp = CreateObject("Outlook.Application")

'Create a new message
Set oItem = oOutlookApp.CreateItem(olMailItem)
With oItem
.To = ToAddress
.CC = CCAddress3
.Subject = MailSub

'Bring up new mail window
oItem.Display

'Add Attachment
oItem.Attachments.Add fpath

'Cleanup , baby
Set OutMail = Nothing
Set OutApp = Nothing
Set fs = CreateObject("Scripting.FileSystemObject")

fs.deletefile fpath

End With
End Sub


Any help would be greatly appreciated. I am still learning when it comes to using these scripts so be easy on me please! Thanks in advance.