I need to create an Excel file from within Navision and then I need to save this excel file as a .PDF file, in order to do this I need to execute code similar to this excel macro from Navision
" ActiveWindow.SelectedSheets.PrintOut Copies:=1, ActivePrinter:= _
"Amyuni PDF Converter on LPT1:", Collate:=True"
i have this code in Navision
"XlAppl.ActiveWindow.SelectedSheets.PrintOut"
But I dont know how to pass the parametres
Any ideas ?
Regards
Peter
0
Comments
From the on-line VB Help for Excel, you can find that the 'PrintOut' method has the following signature: The detail description of this method indicates that all of the parameters are optional. However, since you wish to supply the 'Copies', 'ActivePrinter' and 'Collate' parameters, you will have to supply values for each of the parameters up to the 'Collate' parameter.
Try something like this:
thank you
Regards
Peter