#Include <Array.au3>
#include <Date.au3>
const $HKEY_LOCAL_MACHINE = 0x80000002
const $KEY_READ = 0x20019
$lpName=DllStructGetPtr(DllStructCreate('char'))
$lpcName=DllStructGetPtr(DllStructCreate('short'))
$lpClass=DllStructGetPtr(DllStructCreate('char'))
$lpcClass=DllStructGetPtr(DllStructCreate('short'))
;$time=DllStructCreate('char')
$time=DllStructCreate($tagFILETIME);稍微修改
$lpftLastWriteTime=DllStructGetPtr($time)
dim $lpSubKey = 'SOFTWARE\Microsoft'
$phkResult=DllStructGetPtr(DllStructCreate('char'))
$yy=dllcall('Advapi32.dll','long','RegOpenKeyEx','ptr',$HKEY_LOCAL_MACHINE,'str',$lpSubKey,'byte',0,'ptr',$KEY_READ,'int*',$phkResult)
;_ArrayDisplay ($yy)
for $dwIndex= 0 to 5
$tt=dllcall('Advapi32.dll','long','RegEnumKeyEx','ptr',$yy[5],'int',$dwIndex,'str',$lpName,'dword*',$lpcName,'byte',0,'str',$lpClass,'dword*',$lpcClass,'int',$lpftLastWriteTime)
_ArrayAdd ($tt,_Date_Time_FileTimeToStr ($Time))
_ArrayDisplay ($tt)
next
$ww=dllcall('Advapi32.dll','long','RegCloseKey','ptr',$yy[5])
;_ArrayDisplay ($ww)
一帖给5元,你当我5毛啊,多加些!
为什么我得到的时间会晚8小时捏?高手们给看看啊
[ 本帖最后由 kakinkgb 于 2008-6-17 21:58 编辑 ] |