king1980
1st July 2010, 15:33
Hi,

I have written the AFS to run the report, but when i run the AFS no output screen is coming for display

stpapi.put.field("tcibd0401m000", "item.f", " 23512")
stpapi.put.field("tcibd0401m000", "item.t", " 23512")
stpapi.set.report("tcibd0401m000", "rtcibd040112000", "D", error.msg)
if isspace(error.msg) then
stpapi.form.command("tcibd0401m000",5,"exec.cont.process",error.msg)
stpapi.continue.process("tcibd0401m000", error.msg)
else
message(error.msg)
endif

stpapi.end.session("tcibd0401m000")

Please help me to resolve this issue.

Regards
king1980

mark_h
1st July 2010, 18:29
Is this one of those segmented item sessions?

mark_h
1st July 2010, 18:34
I also don't think you need the stpapi.continue, I think in LN you just need the form command.

wiggum
16th July 2010, 16:26
I think it is not possible to print on display via AFS as usually the session called by AFS is not connected to a client. Use a file or a printer for output.

king1980
18th July 2010, 08:34
hi,

I am able to get output for reports to display device .
Only issues when i am trying to run the report where segmented domain is present that time i am not getting out put.
Other wise AFS for report is working fine for other reports where segmented domain is not involved in selection criteria.

Regards
king1980

saurin710
21st July 2010, 09:44
How can i output into file thru AFS ? pls. help me.

manish_patel
21st July 2010, 13:41
How can i output into file thru AFS ? pls. help me.

To print the report to a file, use a file device in stpapi.set.report().

Set the spool.fileout variable, to print the data to another file then the default file for the device.
stpapi.put.field(“<sessioncode>”, “spool.fileout”, myfile)

king1980
22nd July 2010, 08:18
Dear Manish,

I am able to run the report using display device but i have issue only when i am running the report using segmented domain.

I need help on how to handle segmented domain in the AFS Report.

Regards
king