print different page of a report on different printers

cfv
Member Posts: 19
Hello,
I want to print a report in this way :
- the 1st page on a printer
- the other pages on another printer.
I've tried to do it with the function rundll32 printui.dll but it doesnt work.
Is there another solution ?
For example :
WshShell.Run(STRSUBSTNO('rundll32 printui.dll,PrintUIEntry /y /n"%1"',PrinterName1));
and then in an another section
WshShell.Run(STRSUBSTNO('rundll32 printui.dll,PrintUIEntry /y /n"%1"',PrinterName2));
Thank you in advance.
I want to print a report in this way :
- the 1st page on a printer
- the other pages on another printer.
I've tried to do it with the function rundll32 printui.dll but it doesnt work.
Is there another solution ?
For example :
WshShell.Run(STRSUBSTNO('rundll32 printui.dll,PrintUIEntry /y /n"%1"',PrinterName1));
and then in an another section
WshShell.Run(STRSUBSTNO('rundll32 printui.dll,PrintUIEntry /y /n"%1"',PrinterName2));
Thank you in advance.
0
Comments
-
-
Thanks.
but I want to change the printer, not the tray.0 -
Hi,
That is going to be hard to do with only one report object.
What I would do is create a copy of your report and make that copy print all pages except the first page.
Now you have to be careful with the preview mode:
1. When you are in preview mode the original report will print everything.
2. Then when you are NOT in preview mode the original report will only print the first page and call the copy with the records filtered and request form turned off.
Finally you would need to add the new copy report to the "Printer selection" table so it will use the secondary printer.
Hope this helps,
WillyFostering a homeless, abused child is the hardest yet most rewarding thing I have ever done.0 -
I fought with this for ages a few years back, and never got it to work, even getting multiple trays to work was never reliable. In reality though the need was driven by a bad business practice, (i.e. the need for lots of paper) so after a lot of fighting I finally convinced the client to fix the business process.
but if you ever do get this to work (with out the multiple report option) please post the solution.David Singleton0 -
so there is no ideal solution... what a pity !
It's also so difficil to identify the tray number of a printer !
Each time a user is changing of printer, we have to find what number tray to use !
I thus thought that by using 2 printers it would be simpler...
Thanks a lot.0 -
Maybe a PDF printer can help you here.
e.g. FreePDF provides an option to pre- and postprocess PDF files generated using an arbitrary command or script, so you could print the file twice (pg 1 and pg 2..) and then delete the file.
The site is in German, it provides a link to Babel Fish for site translation.
The program itself is translated to 16 languages.
There might be better options in your case, maybe automation with PDFCreator.0 -
Finally I am going to use another method and use the papersource property.
I found an example of code (in VB) which allows to identify tray's numbers.
http://support.microsoft.com/kb/194789
It works well and facilitates my task !0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions