carlosvz21
New Member
- Joined
- Jan 11, 2019
- Messages
- 2
Hi Everyone!
I am curious to see if anyone can help me with this,
I have the following macro to export as a PDF in excel:
Sub SoA()
'
' SoA Macro
'
'
Application.ScreenUpdating = False
Sheets("Super SoA").Select
ChDir "M:\New Client\Created PDF"
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:= _
"M:\New Client\Created PDF\Statement.pdf", Quality:= _
xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False, _
OpenAfterPublish:=False
Application.ScreenUpdating = True
End Sub
We do this all the time for "n"amount of clients, after we export the Statement to pdf, we rename it to add the client's name at the begining of the file's name i.e. "John Smith - Statement.pdf"
Is there any way to code the client's name into the macro to avoid the time in renaming files? to be exported as "John Smith - Statement.pdf" instead of simply "Statement.pdf"?
it sounds silly with 1 client, but we trend to have around 2000 per day so you can imaging the impact on us.
as part of the data entry, we already have the client's name in another sheet/cell --> 'DATA'C5 (Value in this cell will be displaying "John Smith")
Thank you guys for any help you can provide with this!
I am curious to see if anyone can help me with this,
I have the following macro to export as a PDF in excel:
Sub SoA()
'
' SoA Macro
'
'
Application.ScreenUpdating = False
Sheets("Super SoA").Select
ChDir "M:\New Client\Created PDF"
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:= _
"M:\New Client\Created PDF\Statement.pdf", Quality:= _
xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False, _
OpenAfterPublish:=False
Application.ScreenUpdating = True
End Sub
We do this all the time for "n"amount of clients, after we export the Statement to pdf, we rename it to add the client's name at the begining of the file's name i.e. "John Smith - Statement.pdf"
Is there any way to code the client's name into the macro to avoid the time in renaming files? to be exported as "John Smith - Statement.pdf" instead of simply "Statement.pdf"?
it sounds silly with 1 client, but we trend to have around 2000 per day so you can imaging the impact on us.
as part of the data entry, we already have the client's name in another sheet/cell --> 'DATA'C5 (Value in this cell will be displaying "John Smith")
Thank you guys for any help you can provide with this!