rramesh23
17th February 2007, 06:49
Hi ,
I'm trying to update 'Potential Purchase Backorders' through AFS in SSA LN 6.1.
Its niether giving error nor updating.

Following is the code :

stpapi.put.field( "tdpur4101m700", "tdpur401.orno",orno.f)
stpapi.put.field( "tdpur4101m700", "tdpur401.pono", "10")
stpapi.put.field( "tdpur4101m700", "tdpur401.sqnb", "1")
ret = stpapi.find("tdpur4101m700", error)
ret = stpapi.mark("tdpur4101m700", error)
ret = stpapi.change.view( "tdpur4101m700" )
stpapi.put.field( "tdpur4101m700", "tdpur401.orno",orno.f)
stpapi.put.field( "tdpur4101m700", "tdpur401.pono", "10")
stpapi.put.field( "tdpur4101m700", "tdpur401.sqnb", "1")
ret = stpapi.find("tdpur4101m700", error)
ret = stpapi.mark("tdpur4101m700", error)
stpapi.form.command("tdpur4101m700",5,"confirm.backorder",error)
stpapi.end.session( "tdpur4101m700", error)

Can any body help me out ?

Thanks and regards,

mark_h
19th February 2007, 20:16
Can you turn on logging and see what gets into the logfile. You can search this forum to see how to do that.

Other that that - I have to ask why you do a find, mark change view? I would expect either a find or change view command. This would set the current record. Then the form.command should execute the confirm.backorder command.

These are only my observations and I do not use LN, so I do not know what will/will not work. Second it seems to me someone said that it is better to use the new DAL Libraries(not sure if I got this correct) instead of the AFS code in LN.