General discussion

Locked

Urgent!!! Password in VB to match in NT

By t_gamero ·
A Year full of prosperity for every one.

I have a form in VB wich asks for a user and a password. These need to be compared or validated against the user an password in NT.

Is this possible? and if it is, wher can i find information about?

If any one have code already written about it, could please send it to me.

Thanks a lot everybody

Regards

Tony

This conversation is currently closed to new comments.

10 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

Urgent!!! Password in VB to match in NT

by RRV In reply to Urgent!!! Password in VB ...

Not advisable to create a window in VB to do that job. Recomended to use API which in turn calls the same windows password verification screen. search in www.msdn.microsoft.com for VB help.

RV

Collapse -

Urgent!!! Password in VB to match in NT

by t_gamero In reply to Urgent!!! Password in VB ...

Poster rated this answer

Collapse -

Urgent!!! Password in VB to match in NT

by aong In reply to Urgent!!! Password in VB ...

Tony,

Clarifications on how you want to run the VB pgm. Is the VB program (client) running on the NT box or is it on a desktop PC?

Also specs on the machines + OS (include version) would help.

regards,
A

Collapse -

Urgent!!! Password in VB to match in NT

by t_gamero In reply to Urgent!!! Password in VB ...

The question was auto-closed by TechRepublic

Collapse -

Urgent!!! Password in VB to match in NT

by t_gamero In reply to Urgent!!! Password in VB ...

The form will run in a NT client machine

and the operating system will be Windows 2000 or XP

Collapse -

Urgent!!! Password in VB to match in NT

by TimFox2 In reply to Urgent!!! Password in VB ...

After a lot of searching myself, I am currently implementing the code found here. Finding code to do this is not easy. :)

http://tinyurl.com/4u9g

Hope it works out.

TimFox

Collapse -

Urgent!!! Password in VB to match in NT

by t_gamero In reply to Urgent!!! Password in VB ...

The question was auto-closed by TechRepublic

Collapse -

Urgent!!! Password in VB to match in NT

by supanams In reply to Urgent!!! Password in VB ...

Try to import the function. try code below:

' Information functions: get a connection name, and the current user/computer name
Private Declare Function GetComputerName Lib "Kernel32" Alias "GetComputerNameA" _
(ByVal lpBuffer As String, nSize As Long) As Integer


ublic Function acbGetUser(Optional varErr As Variant) As String

' Get the name of the current network user

Dim strBuffer As String
Dim lngRetval As Long
Dim lngSize As Long

' Pick an arbitrarysize to start with. See comments
' in acbGetConnection to see how this all works.
lngSize = conMaxPath
Do
strBuffer = Space(lngSize)
lngRetval = WNetGetUser(0&, strBuffer, lngSize)
Loop Until lngRetval <> ERROR_MORE_DATA
If lngRetval <> NO_ERROR Then
acbGetUser = ""
Else
acbGetUser = TrimNull(strBuffer)
End If
varErr = lngRetval
End Function

Collapse -

Urgent!!! Password in VB to match in NT

by t_gamero In reply to Urgent!!! Password in VB ...

The question was auto-closed by TechRepublic

Collapse -

Urgent!!! Password in VB to match in NT

by t_gamero In reply to Urgent!!! Password in VB ...

This question was auto closed due to inactivity

Back to Web Development Forum
10 total posts (Page 1 of 1)  

Related Discussions

Related Forums