monica1
8th April 2005, 14:29
In session tfcmg2131s000 (Assign Advance / Unallocated Payments to Invoices) when you execute cont.process the session run tfcmg2106s000 (Assign Unallocated/Advance Payments to Invoices).
I try to automatize this session but how can I controle the records in the second session. It's possible?
If I want if to make automatically assignments for an invoice.
stpapi.put.field("tfcmg2131s000", "tfacp200.ifbp", catmp028.ifbp)
stpapi.put.field("tfcmg2131s000", "tfacp200.ttyp", catmp028.ttyp)
stpapi.put.field("tfcmg2131s000", "tfacp200.ninv", str$(catmp028.ninv))
stpapi.put.field("tfcmg2131s000", "tfacp200.line", str$(catmp028.line))
ret = stpapi.find("tfcmg2131s000", mensaje)
if ret = 1 then
|** marcamos el registro que tenemos en la catmp028
ret = stpapi.mark("tfcmg2131s000", mensaje)
if ret = 1 then
|** desde esta sesión ejecutamos el cont.process
stpapi.form.command("tfcmg2131s000", 5 "exec.cont.process" , mensaje) endif
endif
stpapi.end.session("tfcmg2131s000")
Thank you in advance,
I try to automatize this session but how can I controle the records in the second session. It's possible?
If I want if to make automatically assignments for an invoice.
stpapi.put.field("tfcmg2131s000", "tfacp200.ifbp", catmp028.ifbp)
stpapi.put.field("tfcmg2131s000", "tfacp200.ttyp", catmp028.ttyp)
stpapi.put.field("tfcmg2131s000", "tfacp200.ninv", str$(catmp028.ninv))
stpapi.put.field("tfcmg2131s000", "tfacp200.line", str$(catmp028.line))
ret = stpapi.find("tfcmg2131s000", mensaje)
if ret = 1 then
|** marcamos el registro que tenemos en la catmp028
ret = stpapi.mark("tfcmg2131s000", mensaje)
if ret = 1 then
|** desde esta sesión ejecutamos el cont.process
stpapi.form.command("tfcmg2131s000", 5 "exec.cont.process" , mensaje) endif
endif
stpapi.end.session("tfcmg2131s000")
Thank you in advance,