Dear All,
Listing the Wifi Network Adapters
The WiFi_NetworkAdapter class give you access to the main information related to the WiFi network adpaters.
Code:
Thanks
Listing the Wifi Network Adapters
The WiFi_NetworkAdapter class give you access to the main information related to the WiFi network adpaters.
Code:
Code
procedure GetWiFi_NetworkAdapterInfo;
const
WbemUser ='';
WbemPassword ='';
WbemComputer ='localhost';
wbemFlagForwardOnly = $00000020;
var
FSWbemLocator : OLEVariant;
FWMIService : OLEVariant;
FWbemObjectSet: OLEVariant;
FWbemObject : OLEVariant;
oEnum : IEnumvariant;
iValue : LongWord;
begin;
FSWbemLocator := CreateOleObject('WbemScripting.SWbemLocator');
FWMIService := FSWbemLocator.ConnectServer(WbemComputer, 'root\CIMV2', WbemUser, WbemPassword);
FWbemObjectSet:= FWMIService.ExecQuery('SELECT * FROM WiFi_NetworkAdapter','WQL',wbemFlagForwardOnly);
oEnum := IUnknown(FWbemObjectSet._NewEnum) as IEnumVariant;
while oEnum.Next(1, FWbemObject, iValue) = 0 do
begin
Writeln(Format('AdapterType %s',[FWbemObject.AdapterType]));// String
Writeln(Format('AdapterTypeId %s',[FWbemObject.AdapterTypeId]));// Uint16
Writeln(Format('AssociationStatus %s',[FWbemObject.AssociationStatus]));// String
Writeln(Format('AuthenticationStatus %s',[FWbemObject.AuthenticationStatus]));// String
Writeln(Format('AutoSense %s',[FWbemObject.AutoSense]));// Boolean
Writeln(Format('Availability %s',[FWbemObject.Availability]));// Uint16
Writeln(Format('Band %s',[FWbemObject.Band]));// String
Writeln(Format('Caption %s',[FWbemObject.Caption]));// String
Writeln(Format('CcxPowerLevels %s',[FWbemObject.CcxPowerLevels]));// String
Writeln(Format('CcxTpcPower %s',[FWbemObject.CcxTpcPower]));// String
Writeln(Format('CcxVersion %s',[FWbemObject.CcxVersion]));// String
Writeln(Format('ConfigManagerErrorCode %s',[FWbemObject.ConfigManagerErrorCode]));// Uint32
Writeln(Format('ConfigManagerUserConfig %s',[FWbemObject.ConfigManagerUserConfig]));// Boolean
Writeln(Format('Description %s',[FWbemObject.Description]));// String
Writeln(Format('DeviceID %s',[FWbemObject.DeviceID]));// String
Writeln(Format('DisableRfControl %s',[FWbemObject.DisableRfControl]));// Boolean
Writeln(Format('ErrorCleared %s',[FWbemObject.ErrorCleared]));// Boolean
Writeln(Format('ErrorDescription %s',[FWbemObject.ErrorDescription]));// String
Writeln(Format('GUID %s',[FWbemObject.GUID]));// String
Writeln(Format('HardwareRadioState %s',[FWbemObject.HardwareRadioState]));// Boolean
Writeln(Format('IBSSTxPower %s',[FWbemObject.IBSSTxPower]));// Uint16
Writeln(Format('Index %s',[FWbemObject.Index]));// Uint32
Writeln(Format('InstallDate %s',[FWbemObject.InstallDate]));// Datetime
Writeln(Format('Installed %s',[FWbemObject.Installed]));// Boolean
Writeln(Format('InterfaceIndex %s',[FWbemObject.InterfaceIndex]));// Uint32
Writeln(Format('LastAppliedProfile %s',[FWbemObject.LastAppliedProfile]));// String
Writeln(Format('LastErrorCode %s',[FWbemObject.LastErrorCode]));// Uint32
Writeln(Format('MACAddress %s',[FWbemObject.MACAddress]));// String
Writeln(Format('Manufacturer %s',[FWbemObject.Manufacturer]));// String
Writeln(Format('MaxNumberControlled %s',[FWbemObject.MaxNumberControlled]));// Uint32
Writeln(Format('MaxSpeed %s',[FWbemObject.MaxSpeed]));// Uint64
Writeln(Format('Name %s',[FWbemObject.Name]));// String
Writeln(Format('NetConnectionID %s',[FWbemObject.NetConnectionID]));// String
Writeln(Format('NetConnectionStatus %s',[FWbemObject.NetConnectionStatus]));// Uint16
Writeln(Format('NetEnabled %s',[FWbemObject.NetEnabled]));// Boolean
Writeln(Format('NetworkAddresses %s',[FWbemObject.NetworkAddresses]));// String
Writeln(Format('PermanentAddress %s',[FWbemObject.PermanentAddress]));// String
Writeln(Format('PhysicalAdapter %s',[FWbemObject.PhysicalAdapter]));// Boolean
Writeln(Format('PNPDeviceID %s',[FWbemObject.PNPDeviceID]));// String
Writeln(Format('PowerManagementCapabilities %s',[FWbemObject.PowerManagementCapabilities]));// Uint16
Writeln(Format('PowerManagementSupported %s',[FWbemObject.PowerManagementSupported]));// Boolean
Writeln(Format('ProductName %s',[FWbemObject.ProductName]));// String
Writeln(Format('PSPMode %s',[FWbemObject.PSPMode]));// Uint16
Writeln(Format('RadioState %s',[FWbemObject.RadioState]));// Boolean
Writeln(Format('ServiceName %s',[FWbemObject.ServiceName]));// String
Writeln(Format('Speed %s',[FWbemObject.Speed]));// Uint64
Writeln(Format('Status %s',[FWbemObject.Status]));// String
Writeln(Format('StatusInfo %s',[FWbemObject.StatusInfo]));// Uint16
Writeln(Format('SupportedRates %s',[FWbemObject.SupportedRates]));// String
Writeln(Format('TimeOfLastReset %s',[FWbemObject.TimeOfLastReset]));// Datetime
Writeln(Format('TxRate %s',[FWbemObject.TxRate]));// String
Writeln(Format('WiFiAdapterType %s',[FWbemObject.WiFiAdapterType]));// String
Writeln(Format('XpZeroConfigEnabled %s',[FWbemObject.XpZeroConfigEnabled]));// Boolean
FWbemObject:=Unassigned;
end;
end;Thanks

