Claudio Heidel
Guest
|
Posted:
Mon Nov 15, 2004 10:45 pm Post subject:
(-2147024891) Access Denied |
|
|
Hi, I write this message because found a "(-2147024891) Access Denied"
message when I would like run the follow function from a HTA file over
Windows XP SP2.
This function is for check if the Adminstrator password is correct.
I would like know if the Windows SP2 can cause the problem.
Thanks
Hola, escribo este mensaje porque e encontrado un error de "(-2147024891)
Access Denied" cuando quiero ejecutar la siguiente funcion desde un archivo
HTA sobre Windows XP SP2.
Esta funcion es para chequear que la clave de Administrador es correcta.
Quisiera saber si Windows XP SP2 puede estar causando el problema
Gracias
Claudio Heidel
cheidel@harperlynch.com
Harper & Lynch
Function checkPassWord(strPassWord)
Dim oNet
Dim TestDrive
Dim TestShare
Dim bcheckPassWord
Set oNet = CreateObject("WScript.Network")
TestDrive = getNextLetter & ":"
TestShare = "\\" & oNet.ComputerName & "\admin$"
bcheckPassWord = False ' Assume false unless no errors
On Error Resume Next
Err.Clear
oNet.MapNetworkDrive TestDrive, TestShare,,,strPassWord
If Err.number = 0 Then bcheckPassWord = True
checkPassWord = bcheckPassWord
oNet.RemoveNetworkDrive TestDrive, True, True
Set oNet = nothing
End Function |
|