Login   /   Register
Dates and Times

Determine the name of the time zone in which a computer is running

April 1st, 2008 by daniva
     1 votes, average: 3 out of 51 votes, average: 3 out of 51 votes, average: 3 out of 51 votes, average: 3 out of 51 votes, average: 3 out of 5
Loading ... Loading ...

Use the Win32_TimeZone class and check the value of the Description property.

Convert WMI dates to standard dates and times

April 1st, 2008 by daniva
     0 votes, average: 0 out of 50 votes, average: 0 out of 50 votes, average: 0 out of 50 votes, average: 0 out of 50 votes, average: 0 out of 5
Loading ... Loading ...

To convert WMI dates to FILETIME or VT_DATE format or to parse the date into component year, month, day, hours, and so on, you must write your own code.

Determine the day of the week

April 1st, 2008 by daniva
     2 votes, average: 3.5 out of 52 votes, average: 3.5 out of 52 votes, average: 3.5 out of 52 votes, average: 3.5 out of 52 votes, average: 3.5 out of 5
Loading ... Loading ...

Dot.Net Framework provides several classes for dates and times. the primary class is the System.DateTime. The class Represents an instant in time, typically expressed as a date and time of day. The System.DayOfWeek enumeration Specifies the day of the week.

Determine the day of the week

March 31st, 2008 by daniva
     0 votes, average: 0 out of 50 votes, average: 0 out of 50 votes, average: 0 out of 50 votes, average: 0 out of 50 votes, average: 0 out of 5
Loading ... Loading ...

VBScript has a built-in function called DatePart that can take any date you give it and tell you everything from the hour to the minute to the day of the week. All you have to do is pass DatePart two items:
The content you are accessing is for registered users onlyRegisteration is FREE, quick and private.You […]

Tomorrow and Yesterday’s dates

March 31st, 2008 by daniva
     0 votes, average: 0 out of 50 votes, average: 0 out of 50 votes, average: 0 out of 50 votes, average: 0 out of 50 votes, average: 0 out of 5
Loading ... Loading ...

what if you want to retrieve today’s date? But what about yesterday’s date? it’s just as easy to determine yesterday’s date as it is today’s date. That’s because VBScript can do date arithmetic: give it today’s date, and then you can simply subtract 1 day to determine yesterday’s date. In other words: