Hello,
Need help again. I believe I'm close but no bananas! Trying to get a report generated from data inputted in a order form so when the user clicks on a command button it will output this form to the correct subdirectory with the order number as report name. I have done something similar with sending this report via email and it works, but somehow I'm not quite there with the OutputTo. Here's what I am doing so far:
Dim stDocName As String
Dim stOrderNum As String
Dim stSubject
StOrderNum = [Forms]![INPUT FORM]![ORD_NO]
StDocName = "COMPLETED ORDER"
StSubject = "stOrderNum"
DoCom.OutputTo acReport, stDocName, acFormatRTF, \\Serv001\Mkt\Orders\Comp\stSubject,True
I can get this to the correct subdirectory but it's saving it as "stSubject" instead of the order number (like 9256.rtf). When I have done this same thing sending it through email, it does rename the report to the order number. Anyone have any ideas where I'm off?
All help is appreciated. Thanks in advance.
Need help again. I believe I'm close but no bananas! Trying to get a report generated from data inputted in a order form so when the user clicks on a command button it will output this form to the correct subdirectory with the order number as report name. I have done something similar with sending this report via email and it works, but somehow I'm not quite there with the OutputTo. Here's what I am doing so far:
Dim stDocName As String
Dim stOrderNum As String
Dim stSubject
StOrderNum = [Forms]![INPUT FORM]![ORD_NO]
StDocName = "COMPLETED ORDER"
StSubject = "stOrderNum"
DoCom.OutputTo acReport, stDocName, acFormatRTF, \\Serv001\Mkt\Orders\Comp\stSubject,True
I can get this to the correct subdirectory but it's saving it as "stSubject" instead of the order number (like 9256.rtf). When I have done this same thing sending it through email, it does rename the report to the order number. Anyone have any ideas where I'm off?
All help is appreciated. Thanks in advance.