Report runmodel problem

jonnycjonnyc Member Posts: 8
I’m trying to run a report from a codeunit using a pdf creator as a default printer. I have the code implemented to do so but when I call the function Report. Runmodal the report enters in a loop of some kind because it tries to print the report innumerous times. How can I control the report.runmodal?
The parameters I’m using are the following: REPORT.RUNMODAL(31003303,FALSE,TRUE,RecPrint);
31003303 is the report number, false no to display the requisition window, true to use the default printer that is set to pdf creator and RecPrint is the data I’m sending to this report.

Comments

  • kinekine Member Posts: 12,562
    I cannot see from your post if the command is called in some loop in the CU, or the loop is in the report itself etc. Did you tried to use debugger to see what's going on?
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • tinoruijstinoruijs Member Posts: 1,226
    Or perhaps there are no filters put on RecPrint?

    Tino Ruijs
    Microsoft Dynamics NAV specialist
  • WaldoWaldo Member Posts: 3,412
    Indeed.

    Please send the complete code and may be also the dataitems where the reports is built upon.

    Eric Wauters
    MVP - Microsoft Dynamics NAV
    My blog
Sign In or Register to comment.