本帖最后由 dmqhcx88 于 2012/3/12 21:59 编辑
以一个语音计算器为例:先看图:
- #include <GUIConstantsEx.au3>
- #include <WindowsConstants.au3>
- #include <Misc.au3>
- DirCreate(@TempDir&"\AM")
- FileInstall("SkinH_VB6",@TempDir&"\SkinH_VB6.dll")
- FileInstall("skinh",@TempDir&"\skinh.she")
- FileInstall("a2.htm", @TempDir & "\AM\a2.htm")
- FileInstall("a2.swf", @TempDir & "\AM\a2.swf")
- $sDll= DllOpen(@TempDir &"\SkinH_VB6.dll")
- DllCall($sDll, "int", "SkinH_Attach")
- If _Singleton("语音计算器", 1) = 0 Then
- MsgBox(0, "警告", "本程序已在运行,请不要重复运行! ")
- Exit
- EndIf
- $title=" 语音计算器 By dmqhcx88"
- $oIE = ObjCreate("Shell.Explorer.2")
- $Form1 = GUICreate($title, 340, 380, -1, -1 )
- $GUIActiveX = GUICtrlCreateObj($oIE, -100, -11, 540, 420)
- GUISetState()
- $oIE.navigate(@TempDir & "\AM\a2.htm?r=a2.swf")
- ControlListView($title, "", "SysListView321", "ViewChange", "smallicons")
- While 1
- $nMsg = GUIGetMsg()
- Switch $nMsg
- Case $GUI_EVENT_CLOSE
- FileDelete(@TempDir&"\skinh.she")
- FileDelete(@TempDir&"\SkinH_VB6.dll")
- FileDelete(@TempDir&"\AM\a2.htm")
- FileDelete(@TempDir&"\AM\a2.swf")
- DirRemove(@TempDir&"\AM",1)
- Exit
- EndSwitch
- WEnd
复制代码 编译好的程序:
|