Riz Posted August 30, 2006 Posted August 30, 2006 I have got HELP file which is located at the same folder, but when i click the button always sad "Unable to execute the external program" #include <GuiConstants.au3> GuiCreate("MyGUI", 392, 316,-1, -1 , BitOR($WS_OVERLAPPEDWINDOW, $WS_CLIPSIBLINGS)) $Button_1 = GuiCtrlCreateButton("Button1", 150, 100, 100, 30) GuiSetState() While 1 $msg = GuiGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ExitLoop Case $msg = $Button_1 Run(@ScriptDir & "\KHA.chm", "", @SW_MAXIMIZE) Case Else ;;; EndSelect WEnd Exit
spyrorocks Posted August 30, 2006 Posted August 30, 2006 (edited) you gotta run the help file viewer first then the help file as a command line argument. or use the dos "start" command then your help file then it should run. Like this: $file = @scriptdir & "\KHA.chm" run("start " & $file) Edited August 30, 2006 by spyrorocks [center] My Projects: Online AutoIt Compiler - AutoForum - AutoGuestbook - AutoIt Web-based Auto Installer - Pure AutoIt Zipping Functions - ConfuseGen - MindReader - P2PChat[/center]
Riz Posted August 30, 2006 Author Posted August 30, 2006 you gotta run the help file viewer first then the help file as a command line argument. or use the dos "start" command then your help file then it should run.Like this:$file = @scriptdir & "\KHA.chm"run("start " & $file)Thanks for you fast reply but same problem
spyrorocks Posted August 30, 2006 Posted August 30, 2006 are you sure your help file is there? are you able to view the help file when you click it? [center] My Projects: Online AutoIt Compiler - AutoForum - AutoGuestbook - AutoIt Web-based Auto Installer - Pure AutoIt Zipping Functions - ConfuseGen - MindReader - P2PChat[/center]
Riz Posted August 30, 2006 Author Posted August 30, 2006 are you sure your help file is there? are you able to view the help file when you click it?Yes %100 i'm sure
Helge Posted August 30, 2006 Posted August 30, 2006 (edited) I think spyrorocks is having problems with his own helpfile. This might work : $file = @ProgramFilesDir & "\AutoIt3\AutoIt.chm" Run(@ComSpec & ' /c start " " ' & $file & '"', "", @SW_HIDE) Edited August 30, 2006 by Helge
spyrorocks Posted August 30, 2006 Posted August 30, 2006 try thisa: $helpfile = '"' & @scriptdir & '\KHA.chm"' run("C:\windows\hh.exe " & $helpfile) try that i think it should work. [center] My Projects: Online AutoIt Compiler - AutoForum - AutoGuestbook - AutoIt Web-based Auto Installer - Pure AutoIt Zipping Functions - ConfuseGen - MindReader - P2PChat[/center]
Riz Posted August 30, 2006 Author Posted August 30, 2006 try thisa:$helpfile = '"' & @scriptdir & '\KHA.chm"'run("C:\windows\hh.exe " & $helpfile)try that i think it should work.Amzing, its works thanks a lot for your help
spyrorocks Posted August 30, 2006 Posted August 30, 2006 your welcome. i figure i will get it right eventually lol. [center] My Projects: Online AutoIt Compiler - AutoForum - AutoGuestbook - AutoIt Web-based Auto Installer - Pure AutoIt Zipping Functions - ConfuseGen - MindReader - P2PChat[/center]
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now