cancel
Showing results for 
Search instead for 
Did you mean: 

batch invoicing with visual studio

tichaona_gaza
Participant
0 Kudos

Hi guys,

Anyone knows how to use visual studio to edit the A?R invoice so that a person can do batch invoicing.

Accepted Solutions (1)

Accepted Solutions (1)

former_member185682
Active Contributor
0 Kudos

Hi Tichaona,

You can update your invoice using something like this:


                Documents invoice = (SAPbobsCOM.Documents)oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oInvoices);

                int key = 60; //provide the key of your invoice

                if (invoice.GetByKey(key))

                {

                    //edit your fields

                    if(invoice.Update() != 0)

                        MessageBox.Show(oCompany.GetLastErrorDescription());

                }

If you need update a batch of invoice, puts this code in repetition structure like foreach.

Hope it helps,

Regards,

Diego

tichaona_gaza
Participant
0 Kudos

Thanks Diego, quite helpful.

Answers (0)