soir all

Quelqu'un a til reussit à utiliser les exemples du tutoriel WMI ?

j'ai D6, j'arrive à rien ..
le code ci dessous me dit "parametre non valide"



Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
 
procedure TForm1.Button1Click(Sender: TObject);
Var
 
  WMILocator:          TSWbemLocator;
  WmiService:          SWbemServices;
 
  OldCursor:           TCursor;
 
begin
 WMILocator:= TSWbemLocator.Create(self);
 try
 
  OldCursor := Screen.Cursor;
  Screen.Cursor := crSQLWait;
 
  WmiService:= WMILocator.ConnectServer('.', 'ROOT\CIMV2', '', '', '',
                                        '', 16, nil);
 Finally
  WMILocator.Free;
  Screen.Cursor:= OldCursor;
 end;
 
end;
quelqu'un aurrait-il une bonne idée ?

Merci Merci
Cordialement
Ln