Nav 2013 : How to only print the checked records

NewNavUserNewNavUser Member Posts: 6
edited 2014-06-09 in NAV Three Tier
Hi, i'm new to NAV and i have a question about form and report..

I added a new field in the "page - sales line" in NAV called"print" with data type "boolean".
My goal is to make the records with the checked "print checkbox" appear in the printout, and the other is not printed.

Here's the image of the page
PrintCheckbox_zps5ea8ce6c.jpg

What do i do to print only the selected one ?

Comments

  • BenSydneyBenSydney Member Posts: 56
    Hi,

    You can skip the record by putting code on the 'OnAfterGetRecord' trigger of the applicable 'DataItem' in the report.

    It will look something like:

    IF NOT Print THEN
    CurrReport.SKIP;

    Cheers,
    Ben
  • JohnHunterJohnHunter Member Posts: 45
    or Report/DataItem Properties/DataItemTableView/TableFilter Print/Constant/Yes
  • NewNavUserNewNavUser Member Posts: 6
    i've tried both but it won't work :(

    the field "print" (checkbox) is on sales line table, and in the report (Sales line - OnAfterGetRecord()) i tried to put the code

    IF NOT Print THEN
    CurrReport.SKIP;

    even tried to use table filter
    Field Type Value
    Print CONST Yes

    is there another solution ? thx before :)
  • clauslclausl Member Posts: 455
    Filter out the row in RowVisibility in the Layout, but then you pass uneccessary rows in the dataset, so better to do it in NAV.
    But Row Visibilty is easy to do in Visual Studio ;-)

    /Claus Lundstrøm
    Claus Lundstrøm | MVP | Senior Product Manager | Continia.com
    I'm blogging here:http://mibuso.com/blogs/clausl and used to blog here: http://blogs.msdn.com/nav
    I'm also offering RDLC Report Training, ping me if you are interested. Thanks to the 700 NAV developers that have now already been at my training. You know you can always call if you have any RDLC report issues :-)
  • JohnHunterJohnHunter Member Posts: 45
    All 3 options should work.
    Close the page and then ran report ? :-k
  • NewNavUserNewNavUser Member Posts: 6
    Thank you all for your help, it's working :)
Sign In or Register to comment.