× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi Marie,

I agree with the previous contributors, in that the error parameter can be better defined.

I have copied the relevant bits of code here ...

* Interface for the API...
D QSyCUsrA PR ExtPgm('QSYCUSRA')
D AuthIndicatPR 1A
D UserProfilePR 10A const
D QualObjectPR 20A const
D ObjectTypePR 10A const
D AuthorityPR 110A options(*varsize)
D AuthCountPR 10I 0 const
D CallLevelPR 10I 0 const
D ErrorCodePR likeds(szerrds)

...

D szerrds ds
D szerror 256
D szerrprov 10i 0 overlay(szerror)
D szerrret 10i 0 overlay(szerror: *next)
D szerrmsg 7 overlay(szerror: *next)
D szerrres 1 overlay(szerror: *next)
D szerrdata 240 overlay(szerror: *next)

...

QSyCUsrA(AuthIndicator:
UserProfile:
QualObject:
ObjectType:
Authority:
AuthCount:
CallLevel:
SzErrDs);

If there is an error, field szerrmsg wil contain the message id in the form xxxnnnn, which you can look up using WRKMSGF QCPFMSG.
Otherwise, szerrmsg wil be blank.

I am down in Lmerick and you can contact me directly if I can be of more help.

Regards,
John McKay mba
jmckay at mckaysoftware dot ie





On 02/09/2011 16:58, Marie O'Rourke wrote:
Hi

I have the following code and the 'AuthIndicator' variable always comes
back as Y.
I have edited the Authority on the Object so that no-one has *CHANGE
authority and *PUBLIC is *EXCLUDE
I have tried using other User Profiles and i have tried incrementing the
CallLevel variable.

I'm new to using APIs so not exactly sure why this isn't working as
expected. Our AS400 is on V5R4.

Here's my Code
* Interface for the API...
D QSyCUsrA PR ExtPgm('QSYCUSRA')
D AuthIndicatPR 1A
D UserProfilePR 10A const
D QualObjectPR 20A const
D ObjectTypePR 10A const
D AuthorityPR 110A options(*varsize)
D AuthCountPR 10I 0 const
D CallLevelPR 10I 0 const
D ErrorCodePR 500a options(*varsize)

D AuthIndicator S 1A
D UserProfile S 10A
D QualObject S 20A
D ObjectType S 10A
D Authority S 110A
D AuthCount S 10I 0
D CallLevel S 10I 0
D ErrorCode S 500A

/Free
AuthIndicator = ' ';
UserProfile = '*CURRENT';
QualObject = 'CRXXXXPHNO*LIBL';
ObjectType = '*FILE';
Authority = '*CHANGE';
AuthCount = 1;
CallLevel = 0;

QSyCUsrA(AuthIndicator:UserProfile:QualObject:ObjectType:
Authority:AuthCount:CallLevel:ErrorCode);

DSPLY AuthIndicator;

*INLR = *On;

/End-Free



Thanks
Marie
This e-mail is intended only for the addressee named above. The contents should not be copied nor disclosed to any other person. Any views or opinions expressed are solely those of the sender and do not necessarily represent those of QUINN-Insurance Limited (Under Administration), unless otherwise
specifically stated . As internet communications are not secure,
QUINN-Insurance Limited (Under Administration) is not responsible for the contents of this message nor
responsible for any change made to this message after it was sent by the original sender. Although virus scanning is used on all inbound and outbound e-mail, we advise you to carry out your own virus check before opening any attachment. We cannot accept liability for any damage sustained as a result of any software viruses.

====================================================================

QUINN-Insurance Limited (Under Administration) is regulated by the Central Bank of Ireland and regulated by the Financial Services Authority for the conduct of UK
business.

====================================================================

QUINN-Insurance Limited (Under Administration) is registered in Ireland, registration number
240768 and is a private company limited by shares.
Its head office is at Dublin Road, Cavan, Co. Cavan.




This message is for the designated recipient only and may contain privileged, proprietary, or otherwise private information. If you have received it in error, please notify the sender immediately and delete the original. Any other use of the email by you is prohibited.


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 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.