No. printed field shows 0 first time instead of 1

markyTmarkyT Member Posts: 120
Hello, I think this is easy for experts. As you know, in some tables there is the "No. Printed" field that indicates the times that is printed in a given report. But I've noticed that, on first time it shows 0, when logic it should indicate 1. I know I can use "init value":1 on field, but I want to do that on a concrete report. I want it shows 1, instead of 0, and from there it will automatically adding. I've Attain 3.70. How can do that?.
Thanks in advance.

Comments

  • gerrykistlergerrykistler Member Posts: 149
    It needs to be zero when first created on posting as you can post without printing. It also will not update on a preview. If it is not actually updating the first time you print or post and print, I would look at the report as that is where the updating of No. Printed occurs.
    Gerry Kistler
    KCP Consultores
  • markyTmarkyT Member Posts: 120
    Thanks for reply. It doesn't do it on a preview, always on printing. First time you printed it shows 0. The specific problem is that I sent this report to a client (it's an "order confirmation"). Then the client see that it shows 0, then is not very well. Also occurs that client receives "order confirmation" 1 and thinks that is the first confirmation, but we already have send the confirmation 0. It can be very confused. I need that first time prints 1.
    Thanks for help.
  • vijay_gvijay_g Member Posts: 884
    If you are doing post and print then system taking value 1 in this field but if you want to initialize this by 1 then search the codeunit 80/90 by this code.
    "No. Printed" := 0;
    
  • kinekine Member Posts: 12,562
    Ok, you mean that you added the field to the report to print it out, and that there you can see 0?

    If yes, it is ok, because the counter was incremented after the value was read for your report to print it out. You need to inkrement the counter before the value is read or you need to add 1 on the output.
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • gerrykistlergerrykistler Member Posts: 149
    So check your Order Confirmation report. Make sure it is setting the No. Printed before it gets the data to print. Or another option would be to change the source of the field in the report section so it is:

    "No. Printed" + 1

    I am assuming it is updating correctly, so after printing if you look at the order, the No. Printed after the first printing is 1.

    markyT wrote:
    Thanks for reply. It doesn't do it on a preview, always on printing. First time you printed it shows 0. The specific problem is that I sent this report to a client (it's an "order confirmation"). Then the client see that it shows 0, then is not very well. Also occurs that client receives "order confirmation" 1 and thinks that is the first confirmation, but we already have send the confirmation 0. It can be very confused. I need that first time prints 1.
    Thanks for help.
    Gerry Kistler
    KCP Consultores
  • markyTmarkyT Member Posts: 120
    Ok, you mean that you added the field to the report to print it out, and that there you can see 0?

    That's ok; sorry, I had to have said it was printed. Has indeed been as easy as putting "No. printed":=+1 as you said.
    Thanks everybody for your help and time.
Sign In or Register to comment.