sensalim Posted March 13, 2008 Share Posted March 13, 2008 I have this line in my .au3 (compiled to .exe) Run(@AutoItExe & " /AutoIt3ExecuteScript " & "Test.au3" In Test.au3, it has simple GUI window. When ran, it gives error about not finding GUIConstants.au3 in #include section. What do I do? Thanks! Link to comment Share on other sites More sharing options...
Richard Robertson Posted March 13, 2008 Share Posted March 13, 2008 If you are attempting to run this outside of the installation, it will look in the immediate directory for includes. You can always copy and paste the entire file in the place of #include ... and achieve congruent results. Link to comment Share on other sites More sharing options...
MHz Posted March 13, 2008 Share Posted March 13, 2008 @AutoItExe would be looking for the Include folder within it's own directory for GUIConstants.au3. Link to comment Share on other sites More sharing options...
sensalim Posted March 13, 2008 Author Share Posted March 13, 2008 But GUIConstants.au3 is: #include-once ; ------------------------------------------------------------------------------ ; ; AutoIt Version: 3.2 ; Description: Stub file providing compatibility between the new ; library design and the old. ; ; ------------------------------------------------------------------------------ #include <GUIDefaultConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <ComboConstants.au3> #include <ListViewConstants.au3> #include <StaticConstants.au3> #include <ButtonConstants.au3> #include <ListBoxConstants.au3> #include <TabConstants.au3> #include <EditConstants.au3> #include <DateTimeConstants.au3> #include <SliderConstants.au3> #include <TreeViewConstants.au3> #include <ProgressConstants.au3> #include <AVIConstants.au3> #include <UpDownConstants.au3> Won't that be looking for all these au3 files too? What's the best way here to do this thing... Confused. Link to comment Share on other sites More sharing options...
Richard Robertson Posted March 13, 2008 Share Posted March 13, 2008 Yes, it would look for those files too. The best solution is not to use files that #include anything if you plan to use the execute command line. Link to comment Share on other sites More sharing options...
sensalim Posted March 13, 2008 Author Share Posted March 13, 2008 (edited) Ok that sounds good... now I need the hex for $GUI_EVENT_CLOSE Where in help file can I find things like these? Thanks! Edit: It's -3 inside GUIConstantsEx.au3 Edited March 13, 2008 by sensalim Link to comment Share on other sites More sharing options...
MHz Posted March 13, 2008 Share Posted March 13, 2008 (edited) Won't that be looking for all these au3 files too?What's the best way here to do this thing... Confused.Yes it will. Your compiled script acts like AutoIt3.exe with the handling of includes when you use /AutoIt3ExecuteScript. You either need to keep the includes with the compiled script or include them into your main script that /AutoIt3ExecuteScript is being used on. As for constants only, you can use a constants generator to get just constants needed and add them into the script rather then including the constant include files. I use SendToA3X to generate constants for me.Edit:Global Const $GUI_EVENT_CLOSE = -3 Edited March 13, 2008 by MHz Link to comment Share on other sites More sharing options...
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