As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only. Moving forward, myibi is our community platform to learn, share, and collaborate. We have the same Focal Point forum categories in myibi, so you can continue to have all new conversations there. If you need access to myibi, contact us at firstname.lastname@example.org and provide your corporate email address, company, and name.
Connect to myibi
posted May 06, 2011 07:05 PM
I'm looking for advice on how to receive a completion status code from a non-WebFOCUS executable that is initiated with a DOS command from within a FOCEXEC.
If anyone has done this before, can you advise me on how it was accomplished.
Thanks for your time,
Bill Helzing IBI - Chicago
This message has been edited. Last edited by: Kerry, May 12, 2011 03:27 PM
Posts: | Location: 5 IBI - Chicago Consulting | Registered: February 08, 2005
posted May 06, 2011 09:00 PM
I think this has been asked before, or something very similar.
What version of WebFOCUS are you on ?
Please update your signature.
Have you looked at the SYSTEM command.
SYSTEM command Waz...
Prod: WebFOCUS 7.6.10/8.1.04 Upgrade: WebFOCUS 8.2.07 OS: Linux Outputs: HTML, PDF, Excel, PPT In Focus since 1984 Pity the lost knowledge of an old programmer!
Posts: | Location: 6349 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006
posted May 08, 2011 01:03 PM
The real question I suspect is,
How do you return the completion code of third party programs executed using WebFOCUS OS level calls. The answer is, Directly you can't. WebFOCUS does not know or care about the OS level program. The OS level Program does not know or care about WebFOCUS. All reasonable "batch" execution systems allow log writing. The WebFOCUS SYSTEM function waits for completion of the CALL as opposed to ! DOS etc. which does not. Write the log. Map the log to WF. Read the log.
posted May 09, 2011 04:36 AM
what I do make some calls with -WINNT and retrieve the Exit-Code within WebFOCUS.
-WINNT powershell -Command "exit ((get-content xyz.txt).length)"
-SET &COUNT = &EXITRC;
WF 7.6.6 (MRE,BID, DevStudio, partly RC) on Windows 2003 /Apache/Tomcat Output: HTML,Excel,PDF,PPT Adapters: SQL Server, DB2, Oracle
Posts: | Location: 38 Austria, Linz | Registered: June 19, 2009
posted May 09, 2011 09:11 AM
Depending on how complicated the output is, you can also just do a simple redirect.
DOS dir > output.txt
Stores the output of the dir command into the output.txt.
You should then be able to read the output back in using FOCUS and parse it.
WF 71.x, 76.x, 7701, 8.0 Beta OS: Linux, Win2k3, Win2k, Win2k8, WinXP Read-Only Topic
Copyright © 1996-2020 Information Builders