You are not logged in.
Pages: 1
I'm not a script writer, but know the parameters to call for last boot time
XP/2000
systeminfo | find "System Up Time"Vista/Windows 7
systeminfo | find "System Boot Time"this is my current batch file for vista/windows 7 machines, however, if i want to lookup the boottime on xp i'll need a separate batch file.
Cmd /k systeminfo | find "System Boot Time"
/pauseWhat I'm looking for is a batch file to display XP, 2000, Vista, Windows7 last boot.. something that can determine what version the operating system is the print out the information.
Offline
I'm not sure I understand your request exactly. Initially I thought that this is what you are after:
systeminfo | findstr "^System.Up.Time ^System.Boot.Time ^OS.Version ^OS.Name"But reading your post again I'm now wondering if this is what you're actually looking for:
systeminfo | findstr "^System.Up.Time ^System.Boot.Time"Offline
Sorry, bit of a typo.
I've both 2000(XP) systems and Vista, which require a different string to print out System Boot. So, in order to use a single batch file, NOT two, I need some type of "IF" statement(script) to determine which version of windows the batch file runs on, then print our the desired information ("System Up Time" for XP/2000 or "System Boot Time"
Vista/Windows7)
Offline
Yes, that's what I (eventually) thought you were asking. However, if you've tried my second suggestion, you should see that it pulls the correct information out on any of the systems by being a bit more clever about how it selects the lines it wants (without the need to figure out which Windows version it is).
Last edited by bluesxman (2010-01-06 08:04:36)
Offline
Pages: 1