SriksAdi
24th August 2004, 14:46
Hi,
I have a session to create a Credit Note using AFS.
Initially we were on IVc4 SP 14 and it worked well, my session stopped working on installing SP 15 Tools.
I could successfully create a Batch and when I try to insert into tfacr1110s000 (Maitain Sales Invoices), I get an error Customer Name not allowed.
I could notice that the value of tfacr200.cuno was set properly.
Create batch and start tfacr1110s000....
stpapi.handle.subproc("tfgld1101m000", "tfacr1110s000", "add")
stpapi.continue.process("tfgld1101m000", error)
stpapi.put.field("tfacr1110s000", "tfacr200.cuno", tdsls045.cuno)
stpapi.put.field("tfacr1110s000", "tfacr200.ttyp", tdpfl213.ttyp)
stpapi.get.field("tfacr1110s000", "tfacr200.cuno", value)
stpapi.put.field("tfacr1110s000", "screen.amnt", str$(cn.amnt))
stpapi.get.field("tfacr1110s000", "screen.amnt", value)
value = "Cash Discount for :" & str$(tdsls045.orno)
stpapi.put.field("tfacr1110s000", "tfacr200.refr", value)
stpapi.handle.subproc("tfacr1110s000", "tfacr1111s000", "add")
ret = stpapi.insert("tfacr1110s000", 1, error )
if ret = 0 then
stpapi.end.session("tfacr1110s000")
message(error)
return
endif
regards
Sriks
I have a session to create a Credit Note using AFS.
Initially we were on IVc4 SP 14 and it worked well, my session stopped working on installing SP 15 Tools.
I could successfully create a Batch and when I try to insert into tfacr1110s000 (Maitain Sales Invoices), I get an error Customer Name not allowed.
I could notice that the value of tfacr200.cuno was set properly.
Create batch and start tfacr1110s000....
stpapi.handle.subproc("tfgld1101m000", "tfacr1110s000", "add")
stpapi.continue.process("tfgld1101m000", error)
stpapi.put.field("tfacr1110s000", "tfacr200.cuno", tdsls045.cuno)
stpapi.put.field("tfacr1110s000", "tfacr200.ttyp", tdpfl213.ttyp)
stpapi.get.field("tfacr1110s000", "tfacr200.cuno", value)
stpapi.put.field("tfacr1110s000", "screen.amnt", str$(cn.amnt))
stpapi.get.field("tfacr1110s000", "screen.amnt", value)
value = "Cash Discount for :" & str$(tdsls045.orno)
stpapi.put.field("tfacr1110s000", "tfacr200.refr", value)
stpapi.handle.subproc("tfacr1110s000", "tfacr1111s000", "add")
ret = stpapi.insert("tfacr1110s000", 1, error )
if ret = 0 then
stpapi.end.session("tfacr1110s000")
message(error)
return
endif
regards
Sriks