Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Ellora Rakshit
  Where is Ellora Rakshit?
 Dhaka
 Bangladesh
 Ellora Rakshit
 To: Boudewijn Lutgerink
  Where is Boudewijn Lutgerink?
 Hoonaardstraat, Driel
 Netherlands
 Boudewijn Lutgerink
 Tags
Subject: RE: user name for netware login
Thread ID: 22099 Message ID: 22448 # Views: 21 # Ratings: 0
Version: Visual FoxPro 7 Category: Operating Systems
Date: Friday, April 18, 2003 7:37:01 AM         
   


Sorry Mr. Boudewijn due to late response.

I tried with your codes but failed. I applied in XP Home. In every cases it is showing local username only.

Thereafter I visited msdn online. I have found two articles on the aforesaid subject mentioned in the following, but failed to move further. Could you help?

1. PackNALPath Method in Class SMS_NAL_Methods
2. UnPackNALPath Method in Class SMS_NAL_Methods

I would also like to ask you whether 'NWUSERNAME' in VFP 7.0 will able to meet my requirement.

Awaiting a reply.

Regards,


ER

> Would this help?
> Code comes from new2news.com
>
>
> DO decl 
> DO GetNames 
> DO GetNameEx 
> 
> PROCEDURE GetNames 
>     nSize = 250 
>     lpBuffer = SPACE(nSize) 
> 
>     IF GetComputerName (@lpBuffer, @nSize) > 0 
>         lpBuffer = STRTRAN (SUBSTR (lpBuffer, 1, nSize), Chr(0),"") 
>         ? "Computer: " + lpBuffer 
>     ENDIF 
> 
>     nSize = 250 
>     lpBuffer = SPACE(nSize) 
> 
>     IF GetUserName (@lpBuffer, @nSize) > 0 
>         lpBuffer = STRTRAN (ALLTRIM(SUBSTR (lpBuffer, 1, nSize)), Chr(0),"") 
>         ? "User: " + lpBuffer 
>     ENDIF 
> 
> PROCEDURE GetNameEx 
>     LOCAL cBuffer, nBufsize, nIndex 
>     FOR nIndex=0 TO 7 
>         nBufsize = 250 
>         cBuffer = Repli(Chr(0), nBufsize) 
>         IF GetComputerNameEx(nIndex, @cBuffer, @nBufsize) <> 0 
>             ? nIndex, LEFT(cBuffer, nBufsize) 
>         ENDIF 
>     ENDFOR 
> 
> PROCEDURE decl 
>     DECLARE INTEGER GetComputerName IN kernel32; 
>         STRING  @ lpBuffer, INTEGER @ nSize 
> 
>     DECLARE INTEGER GetComputerNameEx IN kernel32; 
>         INTEGER NameType, STRING @lpBuffer, INTEGER @lpnSize 
> 
>     DECLARE INTEGER GetUserName IN advapi32; 
>         STRING  @ lpBuffer, INTEGER @ nSize 
> 
> 

>
> Boudewijn Lutge®ink
> Boudewijn.Lutgerink@foxite.com
> Experience is the knowledge you get immediately AFTER you actually needed it...


Hello Foxite

COMPLETE THREAD

user name for netware login Posted by Ellora Rakshit @ 4/9/2003 1:08:28 PM
RE: user name for netware login Posted by Boudewijn Lutgerink @ 4/9/2003 3:10:14 PM
RE: user name for netware login Posted by Ellora Rakshit @ 4/18/2003 7:37:01 AM
RE: user name for netware login Posted by Ellora Rakshit @ 4/25/2003 5:18:22 AM
RE: user name for netware login Posted by Eric den Doop @ 4/25/2003 7:27:26 AM
RE: user name for netware login "I tested" Posted by Pete Sass @ 4/25/2003 1:50:12 PM
RE: user name for netware login - Working perfect Posted by Ellora Rakshit @ 4/26/2003 10:50:10 AM
RE: user name for netware login - and Password?... Posted by Ellora Rakshit @ 4/27/2003 5:45:17 AM