Is there any way when calling a report from a page to skip the request page and go straight to the print preview?
*This post is locked for comments
Thank you Jonathan, I really appreciate all your help!
this is not possible.
but you can save the report as pdf with command Report.SaveAsPdf, then copy the file from server to client using cu FileManagement (download/upload) and then run and open the created pdf document using your standard pdf tool. from there you can then decide to print the pdf document or not.
When I do set the UserRequestPage to no or False the report goes straight to the printer. I would like to display the print preview without having to press the button.
Change the properties of Report "UseRequestPage" NO.
Yes you can do that in NAV. As archer said you need to have the developer license to access the code of NAV.
If you have the developer license then go to the page where your report is been called and have this code,
ReportVar.UseRequestPage (FALSE);
ReportVar.RUNMODAL;
For more info about the UseRequestPage please refer this link : msdn.microsoft.com/.../dd354924(v=nav.70).aspx
to do that you need a developer license or contact your nav partner.
it's needed to edit the called report in the dev.env. from object designer.
there select the last, empty line of the edited report (dataitems) and view the report properties, set the property userequestpage to false, save the report.
Yes you can do that using setting USEREQUESTPAGE on the report properties to false or through the code you can set that property to false like below example.
SomeReport.USEREQUESTPAGE(FALSE);
SomeReport.RUNMODAL;
Where SomeReport is the variable of the report you want to run.
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 290,902 Super User 2024 Season 2
Martin Dráb 229,302 Most Valuable Professional
nmaenpaa 101,156