Software development, photography, jokes, ....

Sites by me

 
tas-logoTransportation Administration System
snoezelkussen-logo-kleinstSnoezelen Pillows for Dementia
ikzoekeenbegeleider-logoBegeleiders voor gehandicapten
Laat uw hond het jaarlijkse vuurwerk overwinnen
Betuweroute en Kunst
logo 50x50Hey Vos! Je eigen naam@vos.net emailadres?
Kunst in huis? Nicole Karrèr maakt echt bijzonder mooie dingen
nettylogo2Kunst in huis? Netty Franssen maakt ook bijzonder mooie dingen
Professionele opvang bij Gastouderbureau
Kind-Zijn
Salarisadministratie en belastingadvies bij
De Zaak Loont
Zutphense Bomenstichting

Hosting Favorites

 
ANU Internet Services
XelMedia .internet services
register.com
GoDaddy.com

Blogroll

 
Bomenstichting
MacFreak
Google Translate
PHP
MySQL
jQuery
jQuery UI
codecademy
YourHead Stacks API
Favicon Generator. For real.
Check HTTPS problems



Marc's Place

 

E$PGMMSG - Send a message or retrieve object attributes

Start Command

call e$pgmmsg (<request> <message data structure> <queue> <program>)

Call Parameters

request (a4)
Action to perform:
 
Value: *SND
This value instructs the program use the data in the message data structure to send a message from a messagefile to the specified queue.
 
Value: *OBJ
This value instructs the program to retrieve a job attribute and attributes from a *PGM object, specified in queue (the name of the library) and program.
 
message data structure (a161)

Sending a message
The structure has the following subfields when used for sending a message: 
  • Message Identifier: MSGID, Postions 1-7
    The message id is used to retrieve message text from a message file.
  • Message Severity: MSGSV, Positions 8-9
    The severity of the message is retrieved from the message definition and returned to the calling program through this subfield.
  • Message Data: MSGDT, Positions 10-141
    Message data is used for variables defined within the message text (&1, &2, etc.) and used by the message sending command SNDPGMMSG.
  • Message File: MSGFL, Positions 142-161
    This subfield contains two fields of 10 characters each:
    • Library
      The name of the library of the message file to use. Standard value is *LIBL.
    • Messagefile
      The name of the message file to use.
If the message identifier is empty, no message is sent and the message queue *PRV is emptied.
 
queue (a10)
The name of the message queue to send the message to.
 
program (a10)
The name of the program that is sending the message.

Return Parameters

message data structure (a161)

Retrieve Object- and Jobattributes
Data retrieved is returned to the calling programm through this parameter. The structure has the following subfields when used for retrieving data:
  • Object description: TEXT, Positions 1-50
  • OS/400 release where program was compiled: SYSLVL, Positions 51-59
  • Compiler name and release: COMPILER, Positions 60-75
    This field contains two subfields:
    • Compiler name, Positions 1-7 (60-66 of COMPILER)
    • Compiler release, Positions 8-16 (67-75 of COMPILER)
  • Runmode: Job TYPE, Position 76
    This is a job attribute which is converted to 'B' for batch mode and 'I' for interactive mode.
See the source of DS_E$PGM how this data is used.

What it does

Read above.

Examples

See FN_E$MSG for a coding example.

Go to download page
© 1997- Marc Vos (and others) Contact Me