×

Good News Everybody!

The new search engine is LIVE!

Please report any problems to david (at) midrange.com.




Dan,

The W2K environment variable is USERNAME.  USERPROFILE also gives this
info but it's in the form of \%winsysdir%\profiles/.....

To test simply enter "set USERNAME" or "set USERPROFILE" in a DOS window.

Programatically you can use the GetEnvironmentVariableA API to retrieve.

HTH,

Michael Rooney
Citigroup International


-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx]On Behalf Of Dan Bale
Sent: Wednesday, July 14, 2004 9:33 AM
To: midrange-l@xxxxxxxxxxxx
Subject: Way to tie CWBLOGON UserID to W2K logged in UserID?


Looking at CWBLOGON to give me back the function I had before I changed from
Win98 to Win2k.  (CWBLOGON lets you specify an iSeries user ID & password
once for each Windows "session" to be stored in a cache so that you are not
bothered with the prompt for a password every day.)

Wondering how to implement this.  Initially, I was thinking of AUTOEXEC.BAT.
But it occurred to me that it would be better if it ran only under my W2K
logon ID, and not someone else's.  But I am without a clue as to how to do
this.

Is there an environment variable in W2K that identifies the logged on user?

TIA,
db

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...


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

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