ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

Job Alert - messages

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Re: Job Alert - messages

    Tom is doing a fantastic job here and I dont want to step in..
    His solution is the correct one, but if quick and dirty you could always punt!

    and use SNDDST.
    PHP Code:
                                                                                      
             w1email 
    = %trim(emailad(@USER 'L'));                                   
             
    exfmt win1;                                                              
             if 
    w1email <> *blanks;                                                   
                                                                                      
      
    //SNDDST TYPE(*LMSG) TOINTNET((jamie@code400.com)) DSTD('THis is the subject')  
      // LONGMSG('this is the long message')                                          
                                                                                      
              
    cmdstring =  'SNDDST TYPE(*LMSG) TOINTNET((' +                          
                           %
    trim(w1email)                  +                          
                           
    ')) DSTD(' SUBJECT ')' +                       
                           
    ' LONGMSG(' longmessage ')';                   
              
    cmdlength = %len(%trim(cmdstring));                                     
              
    $command(cmdstring:cmdlength);                                          
             endif; 
    for more complex you can use api - QtmmSendMail (attachments - HTML)

    jamie
    All my answers were extracted from the "Big Dummy's Guide to the As400"
    and I take no responsibility for any of them.

    www.code400.com

    Comment


    • #17
      Re: Job Alert - messages

      Hi Jamie,

      I do appreciate all the effort and hard work - You have all been very helpful It's just I can't get the download to work. It seems to be looking for a user space that doesn't exisit. I can get a message theough SNDDST and i have MMAIL working.

      I apologise for coming over badly if i am.
      www.midlifegamers.co.uk

      Comment


      • #18
        Re: Job Alert - messages

        No -- You are not coming over badly...Just didnt want to step on Tom.

        We know we are here to help & Tom wouldnt help you if he didnt want to trust me

        Jamie
        All my answers were extracted from the "Big Dummy's Guide to the As400"
        and I take no responsibility for any of them.

        www.code400.com

        Comment


        • #19
          Re: Job Alert - messages

          Huddy...PM me your email addy, OS version and i'll send you a save file with everything compiled and ready to go (provided your on v5r3 and higher that is...i'm on v6.1 and that's as far back as i can save to). P.S. Jamie...you are sooo right
          I'm not anti-social, I just don't like people -Tommy Holden

          Comment


          • #20
            Re: Job Alert - messages

            even better give me a hour or so to package up the "new & improved" version i'm using and i'll drop it on the website and you can download it from there...i'll post back when i have it done...
            I'm not anti-social, I just don't like people -Tommy Holden

            Comment


            • #21
              Re: Job Alert - messages

              ok the new version is on the web site. just download, ftp to your box and restore. there's also a readme txt member in the QRPGLESRC file that explains a little bit. no time to do real documentation, but then again after it's setup you're pretty much golden.
              I'm not anti-social, I just don't like people -Tommy Holden

              Comment


              • #22
                Re: Job Alert - messages

                Hi Tom, You kindness is greatly appreciated. I shall look forward to seeing that available.

                I was wondering if there were a simplified QSYSOPR monitor version using APIs (similar to Jamie's Job Monitor program) i.e. one program does all.

                Many thanks

                Huddy
                www.midlifegamers.co.uk

                Comment


                • #23
                  Re: Job Alert - messages

                  that program uses APIs to monitor for QSYSOPR messages. that's the whole purpose for it. the source is included so if you need to modify it to accommodate further needs, etc. you can.
                  I'm not anti-social, I just don't like people -Tommy Holden

                  Comment


                  • #24
                    Re: Job Alert - messages

                    Working great thanks

                    I was also wondering, in the event of any disk or partition errors, what error codes are sent to QSYSOPR? I know CPI1165 "disk parity error" is one but any others i should look out for?

                    thanks
                    www.midlifegamers.co.uk

                    Comment


                    • #25
                      Re: Job Alert - messages

                      you'll just have to look for those. *most* of the critical errors produce problem entries which you can check by doing WRKPRB. i have a CL that i run first thing in the morning to help me keep tabs on the system. it's short and sweet (and i'm too lazy to type in all the commands from the command line lol)
                      Code:
                      pgm                  
                                           
                         wrkmsg            
                         wrkmsg qsysopr    
                         wrksyssts         
                         wrkdsksts         
                         wrkprb            
                      endpgm:              
                         rclrsc            
                         return            
                         endpgm
                      just about anything that can impact your system can be determined by checking those. in QSYSOPR any message with an * in front of it is a message you shouldn't ignore but most of those as i said will create a problem entry..which you'll see in the WRKPRB screen.
                      I'm not anti-social, I just don't like people -Tommy Holden

                      Comment


                      • #26
                        Re: Job Alert - messages

                        Hi Tommy,
                        Thanks for the program, well i have a problem here...when i try to compile sndmsgwait.
                        it say RTVSYSVAL in qcopysrc not found and doesnot compile and ends in error.

                        2) When in run the command oncallmnt it says funtionc_, Cannot resolve to object CENTERIT,
                        these all are member in QCOPYSRC and are not present in the SAVF file.

                        Thanks

                        Comment

                        Working...
                        X