klusums
February 11, 2014, 8:03pm
1
Hi,
I have the next job:
ReportRun reportRun;
Args args = new Args(reportstr(‘InventJournalTransTransfer’));
InventJournalTable inventJournalTable;
PrintJobSettings printJobSettings;
;
printJobSettings = new PrintJobSettings();
printJobSettings.setTarget(PrintMedium::Printer);
printJobSettings.preferredTarget(PrintMedium::Printer);
salesFormLetter = new SalesFormLetter_Confirm(false);
salesFormLetter.updatePrinterSettingsFormLetter(printJobSettings.packPrintJobSettings());
inventJournalTable = InventJournalTable::find(‘IJ27897590’);
args.record(inventJournalTable);
reportRun = new Reportrun(args);
reportRun.init();
reportRun.printJobSettings(printJobSettings.packPrintJobSettings());
reportRun.run();
How can I hide the report “InventJournalTransTransfer” when the job is running?
I need to start the printer imediately after the job will be released, not by checking the report.
Thank you!
Sorry, I don’t understand. What do you mean by “hiding a report” and “not checking the report”? Why do you create salesFormLetter in your code snippet and don’t use it? Either something is missing or something shouldn’t be there.
klusums
February 12, 2014, 7:29am
3
Hi Martin,
I need to have the printer run after the Job is done, without checking the report.
About salesFormLetter - I removed that, I dont need this now.
ThomasP
February 12, 2014, 8:19am
4
Hi,
if your requirement is to send the report directly to printer, try the following code in the init() method of the report:
str printer;
showdialog = false;
printer = '\\path\To\PrinterName;
this.DeviceName(printer);
this.setTarget(printmedium::Printer);
super();
hope it helps
Regards,
Thomas
Denis_m
February 12, 2014, 8:30am
5
Hi
Add the follow two lines after reportun.init() :
reportRun.report().interactive(false);
reportRun.query().interactive(False);
Regards
Denis_m
February 12, 2014, 9:42am
7
Great
Remember to set the post as verified solution.
Thanks