L
Legacy 243189
Guest
Hello,
I came into an issue while setting up macro on a workbook i have.
the issue is i need the following sets of actions to be completed when the workbook got opened programmitcally :
save workbook
and save as pdf.
below the macro i have
Private Sub Workbook_Open()
ActiveWorkbook.Save
Basma
End Sub
Sub Basma()
ThisWorkbook.Save
ChDir "C:\NOC_Automation\Parser Reports\Count Reports"
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:= _
"C:\NOC_Automation\Parser Reports\Count Reports\NOC Weekly Trend Reports.pdf", _
Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas _
:=False, OpenAfterPublish:=False
End Sub
the thing is .. when i opened the workbook and close it i got the message do you want to save changes..
this message doesn't suppose to appear cause i already saved the workbook.
Please advise where i got this macro wrong.
thanks,
Basma
I came into an issue while setting up macro on a workbook i have.
the issue is i need the following sets of actions to be completed when the workbook got opened programmitcally :
save workbook
and save as pdf.
below the macro i have
Private Sub Workbook_Open()
ActiveWorkbook.Save
Basma
End Sub
Sub Basma()
ThisWorkbook.Save
ChDir "C:\NOC_Automation\Parser Reports\Count Reports"
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:= _
"C:\NOC_Automation\Parser Reports\Count Reports\NOC Weekly Trend Reports.pdf", _
Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas _
:=False, OpenAfterPublish:=False
End Sub
the thing is .. when i opened the workbook and close it i got the message do you want to save changes..
this message doesn't suppose to appear cause i already saved the workbook.
Please advise where i got this macro wrong.
thanks,
Basma