python - Check the installation date of Windows XP -


is possible check, using python programming languque, time on operating system installed ? mainly, interested in windows xp platform. wonder if there such api in python or trick it.

using windows registry:

import _winreg reg datetime import datetime  key = reg.openkey(reg.hkey_local_machine, r'software\microsoft\windows nt\currentversion') secs = reg.queryvalueex(key, 'installdate')[0] # stored unix timestamp date = datetime.fromtimestamp(secs) 

Comments

Popular posts from this blog

database - VFP Grid + SQL server 2008 - grid not showing correctly -

jquery - Set jPicker field to empty value -

.htaccess - htaccess convert request to clean url and add slash at the end of the url -