anujahthakur
6th December 2014, 10:13
|****************************** declaration section ***************************
declaration:
#ident "@(#)kpanu6166m000 kpB61Oa9cust VHZDVLNAPP1 Rev.No. 2 06 Dec 14 89385851"
table tkpanu511 | Warehouse
#pragma used dll ottstpapihand
extern domain kpcitg cwar.f,cwar.t
functions:
function extern afs.item()
{
String err.msg(255)
long ret.val
stpapi.put.field("kpanu5111m000","kpanu511.cwar","ABC")
ret.val = stpapi.insert("kpanu5111m000",true,err.msg)
if ret.val then
message("Record Inserted successfully")
else
message("Error Occured:" &err.msg)
endif
ret.val = stpapi.find("kpanu5111m000", err.msg)
if ret.val = 1 then
stpapi.get.field("kpanu5111m000", "kpanu511.cwar", o.cwar)
endif
stpapi.end.session("kpanu5111m000")
}
I am gettiing errors for d above script
pkpanu6166m0000( 40): Error: 'o.cwar' not declared
pkpanu6166m0000( 40): Error: Unknown type of argument 3 for function 'stpapi.get.field'.
pkpanu6166m0000( 40): Error: Argument 3 for function 'stpapi.get.field' has illegal type.
pkpanu6166m0000( 40): Error: Illegal type combination: '? should be: string'
1 warning suppressed due to errors.
4 ERRORS REPORTED.
declaration:
#ident "@(#)kpanu6166m000 kpB61Oa9cust VHZDVLNAPP1 Rev.No. 2 06 Dec 14 89385851"
table tkpanu511 | Warehouse
#pragma used dll ottstpapihand
extern domain kpcitg cwar.f,cwar.t
functions:
function extern afs.item()
{
String err.msg(255)
long ret.val
stpapi.put.field("kpanu5111m000","kpanu511.cwar","ABC")
ret.val = stpapi.insert("kpanu5111m000",true,err.msg)
if ret.val then
message("Record Inserted successfully")
else
message("Error Occured:" &err.msg)
endif
ret.val = stpapi.find("kpanu5111m000", err.msg)
if ret.val = 1 then
stpapi.get.field("kpanu5111m000", "kpanu511.cwar", o.cwar)
endif
stpapi.end.session("kpanu5111m000")
}
I am gettiing errors for d above script
pkpanu6166m0000( 40): Error: 'o.cwar' not declared
pkpanu6166m0000( 40): Error: Unknown type of argument 3 for function 'stpapi.get.field'.
pkpanu6166m0000( 40): Error: Argument 3 for function 'stpapi.get.field' has illegal type.
pkpanu6166m0000( 40): Error: Illegal type combination: '? should be: string'
1 warning suppressed due to errors.
4 ERRORS REPORTED.