O'Reilly logo

APIs at Work, Second Edition by Ron Hawkins, Doug Pence, Bruce Vining

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Swapping the Active User Profile

There is a family of security-related APIs that allow you to swap the current user profile associated with a job to another user profile. These APIs use a handle, which is a Char(12) character variable representing a user profile on the system. Handles are temporary—they are deleted when your job ends, and they cannot be shared across jobs.

You can use APIs such as Get Profile Handle (QsyGetProfileHandle) and Get Profile Handle No Password (QsyGetProfileHandleNoPwd) to get a handle. As you might expect from their names, QsyGetProfileHandle is used when you want to validate the password along with the user profile name, and QsyGetProfileHandleNoPwd is used when you want to run under an authorized profile and do ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required