problem in printing purchase order report

Markandey_PandeyMarkandey_Pandey Member Posts: 178
Hi all,

I am facing some problems while printing report purchase order report:

1.
when i am printing the Blanket Purchase Order Report, i am getting this error:

The Purchase Header does not exist
Identification fields and values:
Document Type='Blanket Order',No='Order no'


2. I want to take two different print from purchase order so i have skipped 'Report Selection' table and have written the following code to print the report:

RepRegularpo -->Report --> MyCustomized Purchase Order report

CLEAR(RepRegularpo);
PurchaseHeader.RESET;
PurchaseHeader.SETRANGE("No.","No.");
IF PurchaseHeader.FINDFIRST THEN BEGIN
RepRegularpo.SETTABLEVIEW(PurchaseHeader);
RepRegularpo.RUNMODAL;
END ELSE
ERROR(Text001);

But the request to print the document is not going to printer.

can anybody help me.
Markandey Pandey

Comments

  • kapamaroukapamarou Member Posts: 1,152
    Can you rerun the processes having activated the debugger and tell us where you get the error?

    The first one could be a GET or a FIND with no IF so when the record does not exist it throws an error message.

    In your second issue do you get an error?
  • SavatageSavatage Member Posts: 7,142
    Where you have
    PurchaseHeader.SETRANGE("No.","No.");

    any reason not to setrange on the "document type" too?
  • Markandey_PandeyMarkandey_Pandey Member Posts: 178
    kapamarou wrote:
    Can you rerun the processes having activated the debugger and tell us where you get the error?

    The first one could be a GET or a FIND with no IF so when the record does not exist it throws an error message.

    In your second issue do you get an error?


    In second issue there is no error but the request to print the document is not going to printer.
    Markandey Pandey
Sign In or Register to comment.