- 1. Obtenir la date et l'heure (etc. )d'un ordinateur
-
- On Error *
- lcComputer = "."
- Clear
- loWMIService = Getobject("winmgmts:\\" + lcComputer + "\root\cimv2")
- colItems = loWMIService.ExecQuery("Select * from Win32_LocalTime")
- For Each loItem In colItems
- ?"Day: " + Transform(loItem.Day)
- ?"Day Of Week: " + Transform(loItem.Dayofweek)
- ?"Hour: " + Transform(loItem.Hour)
- ?"Minute: " + Transform(loItem.Minute)
- ?"Month: " + Transform(loItem.Month)
- ?"Quarter: " + Transform(loItem.Quarter)
- ?"Second: " + Transform(loItem.Second)
- ?"Week In Month: " + Transform(loItem.WeekInMonth)
- ?"Year: " + Transform(loItem.Year)
- ?
- Next
-
- 2. Recherche de l'information de fuseau horaire pour un ordinateur
-
- On Error *
- lcComputer = "."
- Clear
- loWMIService = Getobject("winmgmts:\\" + lcComputer + "\root\cimv2")
- colItems = loWMIService.ExecQuery("Select * from Win32_TimeZone")
- For Each loItem In colItems
- ?"Bias: " + Transform(loItem.Bias)
- ?"Caption: " + Transform(loItem.Caption)
- ?"Daylight Bias: " + Transform(loItem.DaylightBias)
- ?"Daylight Day: " + Transform(loItem.DaylightDay)
- ?"Daylight Day Of Week: " + Transform(loItem.DaylightDayOfWeek)
- ?"Daylight Hour: " + Transform(loItem.DaylightHour)
- ?"Daylight Millisecond: " + Transform(loItem.DaylightMillisecond)
- ?"Daylight Minute: " + Transform(loItem.DaylightMinute)
- ?"Daylight Month: " + Transform(loItem.DaylightMonth)
- ?"Daylight Name: " + Transform(loItem.DaylightName)
- ?"Daylight Second: " + Transform(loItem.DaylightSecond)
- ?"Daylight Year: " + Transform(loItem.DaylightYear)
- ?"Description: " + Transform(loItem.Description)
- ?"Setting ID: " + Transform(loItem.SettingID)
- ?"Standard Bias: " + Transform(loItem.StandardBias)
- ?"Standard Day: " + Transform(loItem.StandardDay)
- ?"Standard Day Of Week: " + Transform(loItem.StandardDayOfWeek)
- ?"Standard Hour: " + Transform(loItem.StandardHour)
- ?"Standard Millisecond: " + Transform(loItem.StandardMillisecond)
- ?"Standard Minute: " + Transform(loItem.StandardMinute)
- ?"Standard Month: " + Transform(loItem.StandardMonth)
- ?"Standard Name: " + Transform(loItem.StandardName)
- ?"Standard Second: " + Transform(loItem.StandardSecond)
- ?"Standard Year: " + Transform(loItem.StandardYear)
- ?
- Next
-
- 3. Déterminer la différence entre le fuseau horaire d'un ordinateur et le GMT Universel.
-
- lcComputer = "."
- loWMIService = Getobject("winmgmts:" ;
- + "{impersonationLevel=impersonate}!\\" + lcComputer + "\root\cimv2")
- colTimeZone = loWMIService.ExecQuery("Select * from Win32_TimeZone")
-
- For Each loTimeZone In colTimeZone
- ?"Offset: "+ Transform(loTimeZone.Bias)
- Next
1. Obtenir la date et l'heure (etc. )d'un ordinateur
On Error *
lcComputer = "."
Clear
loWMIService = Getobject("winmgmts:\\" + lcComputer + "\root\cimv2")
colItems = loWMIService.ExecQuery("Select * from Win32_LocalTime")
For Each loItem In colItems
?"Day: " + Transform(loItem.Day)
?"Day Of Week: " + Transform(loItem.Dayofweek)
?"Hour: " + Transform(loItem.Hour)
?"Minute: " + Transform(loItem.Minute)
?"Month: " + Transform(loItem.Month)
?"Quarter: " + Transform(loItem.Quarter)
?"Second: " + Transform(loItem.Second)
?"Week In Month: " + Transform(loItem.WeekInMonth)
?"Year: " + Transform(loItem.Year)
?
Next
2. Recherche de l'information de fuseau horaire pour un ordinateur
On Error *
lcComputer = "."
Clear
loWMIService = Getobject("winmgmts:\\" + lcComputer + "\root\cimv2")
colItems = loWMIService.ExecQuery("Select * from Win32_TimeZone")
For Each loItem In colItems
?"Bias: " + Transform(loItem.Bias)
?"Caption: " + Transform(loItem.Caption)
?"Daylight Bias: " + Transform(loItem.DaylightBias)
?"Daylight Day: " + Transform(loItem.DaylightDay)
?"Daylight Day Of Week: " + Transform(loItem.DaylightDayOfWeek)
?"Daylight Hour: " + Transform(loItem.DaylightHour)
?"Daylight Millisecond: " + Transform(loItem.DaylightMillisecond)
?"Daylight Minute: " + Transform(loItem.DaylightMinute)
?"Daylight Month: " + Transform(loItem.DaylightMonth)
?"Daylight Name: " + Transform(loItem.DaylightName)
?"Daylight Second: " + Transform(loItem.DaylightSecond)
?"Daylight Year: " + Transform(loItem.DaylightYear)
?"Description: " + Transform(loItem.Description)
?"Setting ID: " + Transform(loItem.SettingID)
?"Standard Bias: " + Transform(loItem.StandardBias)
?"Standard Day: " + Transform(loItem.StandardDay)
?"Standard Day Of Week: " + Transform(loItem.StandardDayOfWeek)
?"Standard Hour: " + Transform(loItem.StandardHour)
?"Standard Millisecond: " + Transform(loItem.StandardMillisecond)
?"Standard Minute: " + Transform(loItem.StandardMinute)
?"Standard Month: " + Transform(loItem.StandardMonth)
?"Standard Name: " + Transform(loItem.StandardName)
?"Standard Second: " + Transform(loItem.StandardSecond)
?"Standard Year: " + Transform(loItem.StandardYear)
?
Next
3. Déterminer la différence entre le fuseau horaire d'un ordinateur et le GMT Universel.
lcComputer = "."
loWMIService = Getobject("winmgmts:" ;
+ "{impersonationLevel=impersonate}!\\" + lcComputer + "\root\cimv2")
colTimeZone = loWMIService.ExecQuery("Select * from Win32_TimeZone")
For Each loTimeZone In colTimeZone
?"Offset: "+ Transform(loTimeZone.Bias)
Next