topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Wednesday December 11, 2024, 10:47 pm
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Last post Author Topic: Windows Install Date Thingie: I made it!  (Read 103474 times)

nite_monkey

  • Member
  • Joined in 2006
  • **
  • Posts: 753
    • View Profile
    • Just Plain Super
    • Read more about this member.
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #25 on: October 27, 2007, 06:29 PM »
Dunno why yours is reporting something different.  What OS are you running?  Vista?
Windows xp, because I would have to be stupid to use vista unless I bought a new computer, and didn't have a copy of xp to install on it, then I would use vista.
But it doesn't really matter to me, because I don't care when I installed windows, or how long it's been running.
[Insert really cool signature here]

Ralf Maximus

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 927
    • View Profile
    • Read more about this member.
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #26 on: October 27, 2007, 07:05 PM »
Ralf, how are you retrieving uptime?

GetTickCount

Yes, I know: it rolls over every 49.3 days or something, and causes frog die-offs in Canada, and was blamed for the mass terror & hysteria at 11:59 on 1999, but it's the first thing I grabbed in the toolbox.

f0dder

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Posts: 9,153
  • [Well, THAT escalated quickly!]
    • View Profile
    • f0dder's place
    • Read more about this member.
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #27 on: October 27, 2007, 07:10 PM »
Ralf, how are you retrieving uptime?

GetTickCount

Yes, I know: it rolls over every 49.3 days or something, and causes frog die-offs in Canada, and was blamed for the mass terror & hysteria at 11:59 on 1999, but it's the first thing I grabbed in the toolbox.
*grin*

Didn't mean to criticize you, I just think it's too bad to have this flaw in an otherwise pretty nifty little tool. I have a snippet somewhere that grabs the uptime performance counter, which shouldn't roll over, I can look for it if you want to, dunno if it's easy to get working with VB though.
- carpe noctem

Ralf Maximus

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 927
    • View Profile
    • Read more about this member.
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #28 on: October 27, 2007, 07:12 PM »
Sure, send it on.  And I didn't take it as criticism, far from it.  Thanks for playing with my toys!

tomos

  • Charter Member
  • Joined in 2006
  • ***
  • Posts: 11,964
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #29 on: October 28, 2007, 12:09 PM »
I think Brett has beat me by a nose, or whatever
I'm currently on this one

WinInstall02.png

without the help of imaging software, no partitions, well C:  :)
3GB free out of 60 at this stage..

It has worked very well over the 4yrs 9months - running into lots of little problems lately but think that might be more to do with being overly full  :-[

In fairness I moved to new computer about a month ago (install 6 weeks old)
WinInstall01.pngWindows Install Date Thingie: I made it!
...
and
plan to do a cleanout/reinstall/etc on the older before I forget all the stuff I learnt sorting out new pc
Tom

cranioscopical

  • Friend of the Site
  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 4,776
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #30 on: October 28, 2007, 12:50 PM »
This is my backup machine.

nudone

  • Cody's Creator
  • Columnist
  • Joined in 2005
  • ***
  • Posts: 4,119
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #31 on: October 28, 2007, 02:51 PM »
i was going to reinstall windows soon but after seeing you guys with 4 years of xp use i now think i'll just leave things as they are - 4 years is a good target to aim for - and better the devil you know and all that...

cranioscopical

  • Friend of the Site
  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 4,776
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #32 on: October 28, 2007, 03:26 PM »
nudone:  i was going to reinstall windows soon but after seeing you guys with 4 years of xp use i now think i'll just leave things as they are
[/b]

I agree with your point of view.  You know, I'm really very pleased with XP.  I've had tons of stuff on and off the machines (like many of us here).  Very stable, very few problems.  Mind you, I'm only a user, not a developer.

I know I'll be using Vista one day but it won't be soon (did you see the nonsense where it doesn't want to install to a machine with > 3Gb RAM?) 
XP was the first Windows release of which I wasn't an early adopter and I'm very glad that I waited.  I intend doing the same with Vista.


ljbirns

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 229
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #33 on: October 28, 2007, 06:30 PM »
My date is  11/12/2004    but it says   alive 3 yrs  11 months  6 hrs 55 min 29 secs

BUT  from 11/12/2004 to 10/28/2007  should be   2 years, 11 months, 16 days

Is it me ?

Lew

Lew

Darwin

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 6,984
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #34 on: October 28, 2007, 07:09 PM »
I feel much the same way, Chris. I skipped Windows 95 but was an early adopter of 98 and 98 SE before moving to Win2k. I resisted XP for two years before upgrading but it has been a very reliable OS (as, in fairness has Win2k). I've no doubt that after Vista Sp-1 ships it will be fine, but I'm in no rush to move up to it just yet!

tomos

  • Charter Member
  • Joined in 2006
  • ***
  • Posts: 11,964
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #35 on: October 29, 2007, 03:00 AM »
My date is  11/12/2004    but it says   alive 3 yrs  11 months  6 hrs 55 min 29 secs

BUT  from 11/12/2004 to 10/28/2007  should be   2 years, 11 months, 16 days

Is it me ?

Lew

could it be to do with american 11/12/2004 = european 12/11/2004?
nope still doesnt add up :-\
Tom

Renegade

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 13,291
  • Tell me something you don't know...
    • View Profile
    • Renegade Minds
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #36 on: October 29, 2007, 07:34 AM »
That's a very cool little utility! :D

This is my 2003 Server box at home:

Windows-Install-Date-Time-Up-Renegade.png

Not 4 years, but it's never had anything except the original install.

I've had 1 problem the entire time - the graphics card crapped out in 1 output so I can only use 1 monitor with the box until I replace it.

The machine runs 24/7 and is only ever rebooted for updates or if I'm going to do any audio recording, then I reboot (usually).
Slow Down Music - Where I commit thought crimes...

Freedom is the right to be wrong, not the right to do wrong. - John Diefenbaker

Josh

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Points: 45
  • Posts: 3,411
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #37 on: October 29, 2007, 07:38 AM »
InstallDate.jpg

And yes, this is Windows Vista.

Ralf Maximus

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 927
    • View Profile
    • Read more about this member.
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #38 on: October 29, 2007, 05:34 PM »
My date is  11/12/2004    but it says   alive 3 yrs  11 months  6 hrs 55 min 29 secs

BUT  from 11/12/2004 to 10/28/2007  should be   2 years, 11 months, 16 days

Is it me ?

Lew

could it be to do with american 11/12/2004 = european 12/11/2004?
nope still doesnt add up :-\

Aieee!  Yep, it's a bug.  Certain circumstances display an extra year in there.  Consider it a bonus.

I've fixed it in v1.2, below.  Also new in this build:

- Switched from using GetTickCount() to WMI's LastReboot parameter.  This prevents the clock from "rolling over" every 25 days, for servers and Windows users who never reboot.  That is, those users who never touch the mouse or keyboard.

- Added File & Options menu drop-down.  Options has a "Don't Care" mode for nite_monkey.

Live damn you!.jpg

Share and Enjoy,
Ralf

jgpaiva

  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 4,727
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #39 on: October 29, 2007, 06:07 PM »
 ;D ;D brilliant

ljbirns

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 229
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #40 on: October 29, 2007, 06:21 PM »
Ralf

That solves my extra year.   :Thmbsup:
Lew

Ath

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 3,629
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #41 on: November 05, 2007, 05:08 PM »
Hm, it's a bit funny that it thinks my PC was on for the last nearly half year, as I've just powered it up tonight...
Screenshot - 6-11-2007 , 0_04_18.png

f0dder

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Posts: 9,153
  • [Well, THAT escalated quickly!]
    • View Profile
    • f0dder's place
    • Read more about this member.
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #42 on: November 05, 2007, 05:28 PM »
Hm, it's a bit funny that it thinks my PC was on for the last nearly half year, as I've just powered it up tonight... (see attachment in previous post)
Do you use hibernation?
- carpe noctem

jgpaiva

  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 4,727
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #43 on: November 05, 2007, 08:30 PM »
Interesting.. I got something similar:

Screenshot-07_11_06,02_29_47.png
I think it has been on for those 3h 7m, just not for those 178 days :P

(nope, no hibernation.. that's evil! ;) )

uryan

  • Participant
  • Joined in 2007
  • *
  • default avatar
  • Posts: 7
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #44 on: November 05, 2007, 10:51 PM »
Definitely something wrong in 1.2

BTW, that 4yrs 5mths is without backups and I have never even used safe mode. For some reason it has always refused to boot up into safe mode

Ralf Maximus

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 927
    • View Profile
    • Read more about this member.
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #45 on: November 06, 2007, 06:02 AM »
Yikes!  Something indeed is weird.

The first number (Install Date) comes straight out of the registry; I'm just reading the number and displaying it.  Reasons that number might be wrong for you (just guessing):

- Machine came from a vendor who pre-installed Windows years ago, then imaged it.  They build new PCs by installing the image.

- Some other app twiddled the registry setting in question for some mysterious and unknowable-by-man reason.

- Registry got "fixed" at one time in the past by restoring a backup from a registry cleaning tool, and the backup was from an old version.

The second number (alive time) comes from the WMI (Windows Management Instrumentation) "last reboot" date.  Again, that's the number handed over by Windows when that value is requested.  A logical person might assume Windows is actually resetting that value upon startup, but I'm not certain of anything anymore...

I'll do some research on when WMI resets that value and see what I can learn.  Anyone with more WMI knowledge/experience than I please feel free to chime in.

uryan

  • Participant
  • Joined in 2007
  • *
  • default avatar
  • Posts: 7
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #46 on: November 06, 2007, 08:06 AM »
What WMI class are you using?

With Win32_OperatingSystem.LastBootUpTime I get the correct boot time as a datetime

With Win32_PerfFormattedData_PerfOS_System.SystemUpTime I get the correct uptime in seconds

Ralf Maximus

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 927
    • View Profile
    • Read more about this member.
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #47 on: November 06, 2007, 08:10 AM »
LastBootUpTime.  And it works on every piece of hardware I own.

Yarrrrrr!

Under what circumstances wouldn't this work?  Can WMI be subverted or get confused?

uryan

  • Participant
  • Joined in 2007
  • *
  • default avatar
  • Posts: 7
    • View Profile
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #48 on: November 06, 2007, 03:26 PM »
Nothing wrong with WMI. You are using some region-sensitive conversions in there.

Ralf Maximus

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 927
    • View Profile
    • Read more about this member.
    • Donate to Member
Re: Windows Install Date Thingie: I made it!
« Reply #49 on: November 06, 2007, 06:34 PM »
Nothing wrong with WMI. You are using some region-sensitive conversions in there.

MMmmmmaybe, but everything else I've done has been regionally sensitive (see the screenshots from the UK and Europe above to see what I mean). 

I'll check the source code and make sure I'm not assuming anything.  Thanks for the tip!