Ciao a tutti, io ho una pag. ASP a cui passo tramite un software (siteminder) un parametro LDAP, per la precisione l'accountExpires, solo che quando lo stampo a video, invece di avere una data tipo 15/5/2005 ho un numero tipo 122514445000, questo perchè, mi sono documentato, il conteggio dell'account inizia dal 1/1/1601 !!W Microsoft
![]()
Ora, ho un VBS che mi converte quel numerone in una data umana, il vbs è il seguente:
Dim dtmValue
Const E_ADS_PROPERTY_NOT_FOUND = &h8000500D ' LINE 3
strPath = InputBox("Insert User ADsPath","Insert Path","LDAP://spsv00im/CN=SPCO998,OU=Temporary Area,DC=pippo,DC=it")
If Len(strPath) = 0 Then
wscript.quit
End If
Set objUser = GetObject(strPath)
dtmValue = objUser.LastLogin
If Err.Number = E_ADS_PROPERTY_NOT_FOUND Then
WScript.Echo "The user has never logged on."
WScript.Quit
Else
WScript.Echo "Last login was on " & _
DateValue(dtmValue) & " at " & TimeValue(dtmValue)
End IF
_____
dtmValue = objUser.AccountExpirationDate
WScript.Echo "Account Expires on " & _
DateValue(dtmValue) & " at " & TimeValue(dtmValue)
______
questo pezzo è quello che mi converte la data in un valore comprensibile......qualcuno sa come posso adattarlo alla mia pag. ASP??![]()
grazie

W Microsoft
Rispondi quotando
