| 
 | 
Hello,
I'm trying to get either the QSYGETPH API or the QsyGetProfileHandle API to work and not having much luck. No matter what I send to them I get back a null value. I've tried using CL and RPG but am having no real luck. Does anyone have any examples from their own usage?
Here's an excerpt from a working program that uses this API:
     D QSYGETPH        PR                  ExtPgm('QSYGETPH')
     D   UsrPrf                      10A   CONST
     D   Passwd                      10A   CONST
     D   Handle                      12A
     D   ErrorCode                32767A   OPTIONS(*NOPASS: *VARSIZE)
     D   PwdLen                      10I 0 const options(*nopass)
     D   CCSID                       10I 0 const options(*nopass)     D dsEC            DS
     D  dsECBytesP                   10I 0 INZ(%size(dsEC))
     D  dsECBytesA                   10I 0 INZ(0)
     D  dsECMsgID                     7A
     D  dsECReserv                    1A
     D  dsECMsgDta                  240A      .
      .     C* check user/password
     c                   callp     QSYGETPH( wkUsrPrf
     c                                     : wkPasswd
     c                                     : wkHandle
     c                                     : dsEC
     c                                     : 10
     c                                     : -1       )     c                   if        dsECBytesA > 0
     c                   eval      wkErrMsg = 'Error ' + dsECMsgID
     c                                      + 'calling QSYGETPH API'
     C******  In my program, I send wkErrMsg over a socket to a
     C******  client program, but you could put it on a screen or
     C******  whatever.
     C                   endifAs an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.