NAS calling report

bobnavisionbobnavision Member Posts: 159
Hi,

Can we call a report from code unit 1 using NAS?
This report is set to processing only and requestformrequired to false.

Regards

Comments

  • DenSterDenSter Member Posts: 8,307
    I'd have to try to make sure, I would typically write a codeunit to do anything in NAS. The only benefit of using a report over a codeunit is that you don't have to program the looping mechanism, and that's not really difficult.
  • bobnavisionbobnavision Member Posts: 159
    Hi,

    My Problem is client do not have Codeunit on their license.
    I am not using any dataitem on report. I am just calling the function on that report.

    rgds
  • DenSterDenSter Member Posts: 8,307
    So I guess we should be asking you then... does it work?
  • krikikriki Member, Moderator Posts: 9,118
    I think it works, but the NAS starts codeunit 1 that starts the report. Once the report is finished, it returns to codeunit 1 that exits. And the NAS remains active, but no Navision code can be run anymore.
    So you would have to make an endless loop (with a sleep in it to avoid that it takes up all the processor) in the report (or also in codeunit 1). In this loop, you should read a NAS-setup-record (new table to make) in which you put a boolean to tell the NAS to continue or to stop. If you keep the endless loop, you are not able to stop the service.
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • bobnavisionbobnavision Member Posts: 159
    This works!!!!!
Sign In or Register to comment.