Jump to content

Search the Community

Showing results for tags '\#include wildcards'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements and Site News
    • Administration
  • AutoIt v3
    • AutoIt Help and Support
    • AutoIt Technical Discussion
    • AutoIt Example Scripts
  • Scripting and Development
    • Developer General Discussion
    • Language Specific Discussion
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • AutoIt Team
    • Beta
    • MVP
  • AutoIt
    • Automation
    • Databases and web connections
    • Data compression
    • Encryption and hash
    • Games
    • GUI Additions
    • Hardware
    • Information gathering
    • Internet protocol suite
    • Maths
    • Media
    • PDF
    • Security
    • Social Media and other Website API
    • Windows
  • Scripting and Development
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • Forum
  • AutoIt

Calendars

  • Community Calendar

Found 1 result

  1. Hello, I work together with a second person on a script. We create functions and each function is stored in a separate file (to not disturb other functions and avoid merging and so on...) Currently in the main script there is a #include section actually looking something like this: (of course we use better names than _func[1-3] :-) ) #include <include_func1.au3> #include <include_func2.au3> #include <include_func3.au3> ... If a new function comes up, someone has to include them by a single line. Not much to do. But I was thinking if some code like this is possible. $FileList_Includes=_FileListToArray("include","_func*.au3",1) _arraydisplay($FileList_Includes) for $i=1 to ubound($FileList_Includes-1) #include "'&$FileList_Includes[$i]&'" next of course the actual line #include "'&$FileList_Includes[$i]&'" au3check : ERROR: can't open include file "'&$FileList_Includes[$i]&'" #include "'&$FileList_Includes[$i]&'" than I came up with the idea to "build" the include file with a script like this: _BUILD_MY_INCLUDE.AU3/EXE #Include <File.au3> #Include <Array.au3> local $IncludeFilename="_MY_Include.au3" local $IncludePath="include" $FileList_Includes=_FileListToArray($IncludePath&"","*.au3",1) ;~ _arraydisplay($FileList_Includes) FileOpen($IncludeFilename,2) for $i=1 to ubound($FileList_Includes)-1 ConsoleWrite($FileList_Includes[$i]&@CRLF) FileWriteLine($IncludeFilename,'#include "'&$IncludePath&""&$FileList_Includes[$i]&'"') next FileClose($IncludeFilename) This script creates a file named: _MY_Include.au3 #include <include_func1.au3> #include <include_func2.au3> #include <include_func3.au3> and than add this with #AutoIt3Wrapper_Run_Before=_BUILD_MY_INCLUDE.EXE and in the main script there is onyl a single include of #include "_MY_Include.au3" surprisingly enough (for me) this is working, but only if I build. Question: If there something I could also use on "GO" in Scite without building the file? Or something simpler than my construction? I tried as always the forum search but "include" is entry that is found "always"...
×