J'ai un script qui effectue une op=E9ration sur une station:
On Error Resume Next
const HKEY_LOCAL_MACHINE =3D &H80000002
strComputer =3D "CEN-S1-EXPLOIT1"
Set objWMIService =3D GetObject("winmgmts:\\" & strComputer=20
& "\root\cimv2")
If Err =3D 462 Then
MsgBox "Poste non joignable"
Else
MsgBox "Poste joignable"
Set oReg =3D GetObject("winmgmts:\\" & strComputer=20
& "\root\default:StdRegProv")
strKey =3D "SOFTWARE\ServiceInfoBM\Millennium"
strValueName1 =3D "NbSession"
strValueName2 =3D "VerVbs"
oReg.GetExpandedStringValue HKEY_LOCAL_MACHINE, strKey,=20
strValueName1, strNbSess
If IsNull(strNbSess) Or Err =3D 424 Then strNbSess =3D "Cl=E9=20
non d=E9finit"
MsgBox strNbSess
End if
Ce script fonctionne tr=E8s bien =E0 l'exception pr=EAt qu'il=20
copie une partie de mon profil user windows sur le poste=20
que je teste !!!!
Comment puis emp=EAcher cela, il me copie environ 300ko=20
(j'ai 230 PC =E0 tester :o/) et lorsque je souhaite le=20
supprimer manuellement, il me dit en cours d'utilisation:
c:\Documents and Settings\UserTest\Local=20
Settings\Application Data\Microsoft\Windows\UserClass.dat
Merci pour vos lumi=E8res pr=E9cieuses.
Amicalement,
Thierry
Cette action est irreversible, confirmez la suppression du commentaire ?
Signaler le commentaire
Veuillez sélectionner un problème
Nudité
Violence
Harcèlement
Fraude
Vente illégale
Discours haineux
Terrorisme
Autre
Thierry
J'ai testé d'autre script, il semble que c'est lorsque je veux interroger la base de registre que cela se produit. Sur le poste de mon collègue cela ne se produit pas avec son login. Amicalement Thierry
-----Message d'origine----- Bonjour,
J'ai un script qui effectue une opération sur une station:
On Error Resume Next const HKEY_LOCAL_MACHINE = &H80000002 strComputer = "CEN-S1-EXPLOIT1" Set objWMIService = GetObject("winmgmts:" & strComputer & "rootcimv2") If Err = 462 Then MsgBox "Poste non joignable" Else MsgBox "Poste joignable" Set oReg = GetObject("winmgmts:" & strComputer & "rootdefault:StdRegProv") strKey = "SOFTWAREServiceInfoBMMillennium" strValueName1 = "NbSession" strValueName2 = "VerVbs" oReg.GetExpandedStringValue HKEY_LOCAL_MACHINE, strKey,
strValueName1, strNbSess If IsNull(strNbSess) Or Err = 424 Then strNbSess = "Clé
non définit" MsgBox strNbSess End if
Ce script fonctionne très bien à l'exception prêt qu'il copie une partie de mon profil user windows sur le poste que je teste !!!!
Comment puis empêcher cela, il me copie environ 300ko (j'ai 230 PC à tester :o/) et lorsque je souhaite le supprimer manuellement, il me dit en cours d'utilisation: c:Documents and SettingsUserTestLocal SettingsApplication DataMicrosoftWindowsUserClass.dat
Merci pour vos lumières précieuses. Amicalement, Thierry .
J'ai testé d'autre script, il semble que c'est lorsque je
veux interroger la base de registre que cela se produit.
Sur le poste de mon collègue cela ne se produit pas avec
son login.
Amicalement
Thierry
-----Message d'origine-----
Bonjour,
J'ai un script qui effectue une opération sur une station:
On Error Resume Next
const HKEY_LOCAL_MACHINE = &H80000002
strComputer = "CEN-S1-EXPLOIT1"
Set objWMIService = GetObject("winmgmts:\" & strComputer
& "rootcimv2")
If Err = 462 Then
MsgBox "Poste non joignable"
Else
MsgBox "Poste joignable"
Set oReg = GetObject("winmgmts:\" & strComputer
& "rootdefault:StdRegProv")
strKey = "SOFTWAREServiceInfoBMMillennium"
strValueName1 = "NbSession"
strValueName2 = "VerVbs"
oReg.GetExpandedStringValue HKEY_LOCAL_MACHINE,
strKey,
strValueName1, strNbSess
If IsNull(strNbSess) Or Err = 424 Then strNbSess
= "Clé
non définit"
MsgBox strNbSess
End if
Ce script fonctionne très bien à l'exception prêt qu'il
copie une partie de mon profil user windows sur le poste
que je teste !!!!
Comment puis empêcher cela, il me copie environ 300ko
(j'ai 230 PC à tester :o/) et lorsque je souhaite le
supprimer manuellement, il me dit en cours d'utilisation:
c:Documents and SettingsUserTestLocal
SettingsApplication DataMicrosoftWindowsUserClass.dat
Merci pour vos lumières précieuses.
Amicalement,
Thierry
.
J'ai testé d'autre script, il semble que c'est lorsque je veux interroger la base de registre que cela se produit. Sur le poste de mon collègue cela ne se produit pas avec son login. Amicalement Thierry
-----Message d'origine----- Bonjour,
J'ai un script qui effectue une opération sur une station:
On Error Resume Next const HKEY_LOCAL_MACHINE = &H80000002 strComputer = "CEN-S1-EXPLOIT1" Set objWMIService = GetObject("winmgmts:" & strComputer & "rootcimv2") If Err = 462 Then MsgBox "Poste non joignable" Else MsgBox "Poste joignable" Set oReg = GetObject("winmgmts:" & strComputer & "rootdefault:StdRegProv") strKey = "SOFTWAREServiceInfoBMMillennium" strValueName1 = "NbSession" strValueName2 = "VerVbs" oReg.GetExpandedStringValue HKEY_LOCAL_MACHINE, strKey,
strValueName1, strNbSess If IsNull(strNbSess) Or Err = 424 Then strNbSess = "Clé
non définit" MsgBox strNbSess End if
Ce script fonctionne très bien à l'exception prêt qu'il copie une partie de mon profil user windows sur le poste que je teste !!!!
Comment puis empêcher cela, il me copie environ 300ko (j'ai 230 PC à tester :o/) et lorsque je souhaite le supprimer manuellement, il me dit en cours d'utilisation: c:Documents and SettingsUserTestLocal SettingsApplication DataMicrosoftWindowsUserClass.dat
Merci pour vos lumières précieuses. Amicalement, Thierry .