Can specify C/AL code for select printer?

teckpohteckpoh Member Posts: 271
Hi All,
I have multiple printer driver, and i wish to print a report to different printer based on some criteria...I wonder whether c/al code support choosing printer by write coding in report?
Coz customer do not like to switch printer periodically when they want to print a report to different printer.

thank in advance~~

Cheer's,
teckpoh

Comments

  • flfl Member Posts: 184
    Yes this is possible. But NOT directly in the report. As soon as the report is started, it's already decided which printer will be used.

    But you could create another report, based on the same tables, but in processingonly=true, so that nothing will be printed. So in this new report, which you start, you can add the code to find out which printer the user needs. Then you can create a record in the printer selection table so that the second report (your current one, which you want to print) is connected to the required printer for this user. From the first report, you then call this report for which you even might pass the filter. The second report will then print on the required printer.
    Francois
    Consultant-Developper

    http://www.CreaChain.com
  • teckpohteckpoh Member Posts: 271
    Dear fl/All,

    Can this be done in a single report? If not how to implement it with alternative ways? fl...thank for ur info, can u explain to me more detail. Thank in advance~~

    regards,
    teckpoh
    fl wrote:
    Yes this is possible. But NOT directly in the report. As soon as the report is started, it's already decided which printer will be used.

    But you could create another report, based on the same tables, but in processingonly=true, so that nothing will be printed. So in this new report, which you start, you can add the code to find out which printer the user needs. Then you can create a record in the printer selection table so that the second report (your current one, which you want to print) is connected to the required printer for this user. From the first report, you then call this report for which you even might pass the filter. The second report will then print on the required printer.
Sign In or Register to comment.