+ Reply to Thread
Results 1 to 3 of 3

Thread: SNDMSG using QCMDEXC

  1. #1
    Guest.Visitor Guest

    Default SNDMSG using QCMDEXC

    You can't use CL-style variables there; it's literally trying to execute the OvrCmd string. Instead, concatenate 'SNDMSG MSG(' with the MsgText with ') TOMSGQ(OAMSGQ)' so that QCMDEXC sees this in OvrCmd: SNDMSG MSG(MsgText) TOMSGQ(OAMSGQ) If the MsgText contains blanks, you may need to add quotes to both ends, so that the OvrCmd looks like this: SNDMSG MSG('MsgText') TOMSGQ(OAMSGQ)

  2. #2

    Default SNDMSG using QCMDEXC

    I'm sending a message to an ASYNC from an ILE pgm using the SNDMSG command. It will not let me use a variable built in the program to send the message. How can I get around this? The code is posted. The message said that &MSGTEXT was not a usable variable with the command. Any help would be greatly appreciated. Thank you, Erik
    Code

  3. #3
    GlenKerner Guest

    Default SNDMSG using QCMDEXC

    simply change the eval statement to say: eval ovrcmd = 'SNDMSG MSG(' + MSGTEXT + ') TOMSGQ(OAMSGQ)' This will give the variable ovrcmd the correct command string needed

+ Reply to Thread

Similar Threads

  1. QCMDEXC
    By Guest.Visitor in forum General
    Replies: 5
    Last Post: 09-12-2003, 12:15 AM
  2. SNDMSG from VB Program
    By Guest.Visitor in forum Programming
    Replies: 4
    Last Post: 09-14-2000, 09:47 AM
  3. why SNDMSG does not work on AS400??
    By Guest.Visitor in forum Application Software
    Replies: 3
    Last Post: 06-16-1999, 11:54 AM
  4. Passing Parms to SNDMSG
    By Guest.Visitor in forum Programming
    Replies: 2
    Last Post: 02-02-1999, 05:12 AM
  5. AS/400 SNDMSG/SNDDST to Lotus Notes
    By Guest.Visitor in forum Application Software
    Replies: 0
    Last Post: 01-01-1995, 02:00 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts