FrenkR
21st December 2011, 01:08
Hi,
if I am running a process via UI (worktop) I see a process tree correctly. For add-ing a new tdsls header I am getting a tree as follows(tdsls4100m000 is presented like child (editing) session of tdsls4100mpol):
tdsls4100mpol
|_ tdsls4100m000
if I call the same function via AFS, I am getting sessions on the same level as follows
tdsls4100mpol
tdsls4100m000
It looks like synchronize.dialog does not open an editing form as a child session. Is that OK or I am doing something wrong?
*end.session* correctly releases both sessions.
AFS code is like this:
ret =stpapi.synchronize.dialog("tdsls4100mpol","add", error.msg)
if ret = 1 then
stpapi.put.field("tdsls4100m000", "tdsls400.ofbp", "100000065")
stpapi.put.field("tdsls4100m000", "tdsls400.stbp", "100000065")
stpapi.put.field("tdsls4100m000", "tdsls400.cofc", "P00")
stpapi.put.field("tdsls4100m000", "tdsls400.sotp", "101")
stpapi.put.field("tdsls4100m000", "tdsls400.orno", "10")
ret = stpapi.insert("tdsls4100m000", true, error.msg)
if not ret then
ret = stpapi.recover("tdsls4100m000", error.msg)
endif
stpapi.end.session("tdsls4100mpol", error.msg)
Best regards,
Frenk
if I am running a process via UI (worktop) I see a process tree correctly. For add-ing a new tdsls header I am getting a tree as follows(tdsls4100m000 is presented like child (editing) session of tdsls4100mpol):
tdsls4100mpol
|_ tdsls4100m000
if I call the same function via AFS, I am getting sessions on the same level as follows
tdsls4100mpol
tdsls4100m000
It looks like synchronize.dialog does not open an editing form as a child session. Is that OK or I am doing something wrong?
*end.session* correctly releases both sessions.
AFS code is like this:
ret =stpapi.synchronize.dialog("tdsls4100mpol","add", error.msg)
if ret = 1 then
stpapi.put.field("tdsls4100m000", "tdsls400.ofbp", "100000065")
stpapi.put.field("tdsls4100m000", "tdsls400.stbp", "100000065")
stpapi.put.field("tdsls4100m000", "tdsls400.cofc", "P00")
stpapi.put.field("tdsls4100m000", "tdsls400.sotp", "101")
stpapi.put.field("tdsls4100m000", "tdsls400.orno", "10")
ret = stpapi.insert("tdsls4100m000", true, error.msg)
if not ret then
ret = stpapi.recover("tdsls4100m000", error.msg)
endif
stpapi.end.session("tdsls4100mpol", error.msg)
Best regards,
Frenk