Report development issue

Get our Free Newletter

Don't you have the time to be online here at DUG every day? So how do you follow what is going on in the Dynamics industry and community?
If you subscribe to the DUG Newsletter then you can relax! We will make sure that you don't miss the big news!

Check out our
Newsletter Subscription Center
page a complete list of our different newsletters.

Not Answered This post has 0 verified solutions | 1 Reply | 1 Follower

6 Posts
235 Points
Joined: 2012-7-26
Last Online:
2012-9-27 12:09
Location: Mumbai, India
Naveen posted on 2012-9-27 11:38

here is the output of the report, the payment is used to settle 4 invoices, but the record is also 4 times, however the other invoice is used to settle one invoice hence it is getting printed once, how to avoid this?

in fetch method i have written the following code

public boolean fetch()

{

    boolean         ret;

    QueryRun        qrun;

    vendtrans       vendtrans_2, vendtrans_3;

    int64           payment_recid, invoice_recid;

    VendSettlement  vendsettlement_2;

    ;

    ret = true;

    qrun = new QueryRun(element);

 

    If(!qrun.prompt())

    {

        return false;

    }

 

    while(qrun.next())

    {

        vendtrans_2 = qrun.get(tablenum(vendtrans));

 

        if(!vendtrans_2)

        {

            return false;

        }

 

        if(vendtrans_2)

        {

            element.send(vendtrans_2);

            while select * from vendsettlement_2 where vendsettlement_2.TransRecId == vendtrans_2.RecId

            {

                select * from vendtrans_3 where vendtrans_3.RecId == vendsettlement_2.OffsetRecid;

                element.send(vendtrans_3);

            }

        }

    }

    return ret;

}

All Replies

Male
6,752 Posts
156,978 Points
Joined: 1995-10-1
Last Online:
2013-5-22 23:58
Location: Middelfart, Denmark
DynamicsNAVMVP
SystemAdministrator
Erik P. Ernst replied on 2012-10-15 8:45

Is this NAV? Looks more like AX.

Best regards,
Erik P. Ernst
Webmaster 

DUG’s Admin's Blog

Don't forget to "Verify Solution" the post(s) that solved your problem. This credits the experts who helped, earns you points and marks your thread as Resolved so we all know you have been helped.

Page 1 of 1 (2 items) | Get this RSS feed | Bookmark and Share