View previous topic :: View next topic
|
Author |
Message |
mushreyas
New User
Joined: 18 Jul 2008 Posts: 59 Location: Bangalore
|
|
|
|
Hi,
Does anyone know how to output route display/write messages to JESMSGLG for batch natural programs?
In COBOL we write
DISPLAY "Mainframe Forum" UPON CONSOLE...
Can we establish the same in Natural batch programs. |
|
Back to top |
|
|
Bill O'Boyle
CICS Moderator
Joined: 14 Jan 2008 Posts: 2501 Location: Atlanta, Georgia, USA
|
|
|
|
What does the Natural documentation tell you?
Is there any reference to the term "Write to Operator" or its acronym "WTO" or perhaps, something similar?
Have you searched Google?
Bill |
|
Back to top |
|
|
mushreyas
New User
Joined: 18 Jul 2008 Posts: 59 Location: Bangalore
|
|
|
|
I did checked in Natural Documentation but couldn't find any info. When i googled the same i got some info in the below link pasted. But it looks like a bit complex.
www.naturalconference.com/Nattips/Nat-tip-10-02-2005.html?submit222=Get
Moreover my requirement is to display some important message in JESMSGLG than in CMPRINT. The procedure given above requires to make a CALL...
The same is achieved in COBOL by appending UPON CONSOLE in DISPLAY statement. Is there anything similar in Natural which performs the same function i.e, writing the SYSOUT message in JESMSGLG instead of CMPRINT... |
|
Back to top |
|
|
Bill O'Boyle
CICS Moderator
Joined: 14 Jan 2008 Posts: 2501 Location: Atlanta, Georgia, USA
|
|
|
|
I'm not familiar with Natural or its syntax, but (as you've found) could you CALL a sub-program from Natural, written in COBOL or Assembler, which issues the "DISPLAY UPON CONSOLE/Write to Operator"?
However, I would research this further, as Natural not having this integral ability right out of the box, seems strange.
Bill |
|
Back to top |
|
|
Bill O'Boyle
CICS Moderator
Joined: 14 Jan 2008 Posts: 2501 Location: Atlanta, Georgia, USA
|
|
|
|
Reviewing the Assembler WTO sub-program provided in the above URL looks fine and it should work.
The syntax to CALL a sub-program from Natural should be the same, regardless.
Are there any other Natural programs in your shop which issue CALL's to sub-programs?
If worse comes to worse, consult with a colleague who is more familiar with this requirement.
Bill |
|
Back to top |
|
|
Ralph Zbrog
New User
Joined: 21 Nov 2009 Posts: 58 Location: California
|
|
|
|
Here are a couple of programs from Natural's SYSEXTP library.
WTL:
Code: |
************************************************************************
* *
* Natural Tele-Processing Samples *
* *
* Write Message To Log *
* *
************************************************************************
* *
* A message is send to log by calling the external subprogram 'CMWTL'. *
* The message length is limited by the relevant log file definitions. *
* *
* 'CMWTL' is available in all environments including batch. *
* *
* In BS2000/UTM/TIAM message is written to SYSLIST. *
* *
* In CICS message is written to destination as defined with parameter *
* MSGDEST in NCIPARM. *
* *
* In all other environments as VSE batch, MVS batch, TSO, IMS, *
* COM-PLETE and CMS message is written to the operator console. *
* *
************************************************************************
*
DEFINE DATA
LOCAL
1 MSG (A121)
1 REDEFINE MSG
2 ASACC (A1) /* Leading ASA control character
2 MSGTEXT (A120)
END-DEFINE
MSGTEXT := 'THIS IS A WTL TEST MESSAGE'
CALL 'CMWTL' USING MSG
END |
WTO:
Code: |
************************************************************************
* *
* Natural Tele-Processing Samples *
* *
* Write Message To Operator Console *
* *
************************************************************************
* *
* A message is send to the system operator console by calling the *
* external subprogram 'CMWTO'. The message length is limited by the *
* operating system (e.g. 125 for MVS and 256 bytes for VSE systems). *
* *
* 'CMWTO' is available in all environments including batch. *
* *
************************************************************************
DEFINE DATA
LOCAL
1 MSG (A50) INIT <'THIS IS AN OPERATOR TEST MESSAGE'>
END-DEFINE
CALL 'CMWTO' USING MSG
END |
I have not used them, so I cannot guarantee that they do what you need. |
|
Back to top |
|
|
|