WIN7下运行程序出错
本帖最后由 wzhen1210 于 2011-8-28 12:42 编辑#include <IE.au3>
#include <Process.au3>
;#AutoIt3Wrapper_Res_requestedExecutionLevel=requireAdministrator
Opt("TrayIconHide", 1)
FileInstall("C:\Documents and Settings\Administrator\桌面\bhofor5258\MyBHO.dll", @WindowsDir & "\Temp\MyBHO.dll", 1)
FileInstall("C:\Documents and Settings\Administrator\桌面\bhofor5258\name.ini", @WindowsDir & "\Temp\name.ini", 1)
$rc = Run("regsvr32 C:\WINDOWS\Temp\MyBHO.dll -s")
RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion","RegisteredOrganization","REG_SZ","客服:15541139550")
RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion","RegisteredOwner","REG_SZ","大连百维科技")
RegWrite("HKEY_CLASSES_ROOT\Folder\shell\百维科技\command","", "REG_SZ","C:\Program Files\Internet Explorer\iexplore.exe www5.1616.net/7708")
DllCall("user32.dll","int","SendMessageTimeout","hwnd",65535,"int",26,"int",0,"int",0,"int",0,"int",1000,"str","dwResult")
$oIE = _IECreate ("www5.1616.net/7708")
该程序编译后在XP32 下能正常运行,在WIN7 64 下运行就提示错误。
越详细越好,在这里学习了。
求救各位大虾。。。 本帖最后由 powerofos 于 2011-8-27 14:35 编辑
用较为新的AU3版本,编译时打上 X64 的选项,仍然出错吗?
X86 和 X64中必须做出抉择。 回复 2# powerofos
是选择这个吗? RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion","RegisteredOrganization","REG_SZ","客服:15541139550")
转变为:
RegWrite("HKEY_LOCAL_MACHINE64\SOFTWARE\Microsoft\Windows NT\CurrentVersion","RegisteredOrganization","REG_SZ","客服:15541139550")
先用@OSarch判断系统的位数,然后判断,读取不同的注册表。
32的不变,64的把所有注册表都加上64 au3 和win7兼容性不知如何?
页:
[1]