Jump to content

#include


 Share

Recommended Posts

  • Developers

for example:

select

  case $a = 1

          $filename = "script1.au3"

  case $a = 2

          $filename = "script2.au3"

endselect

#include $filename

how can i make it works or same result?

thx for hints

<{POST_SNAPBACK}>

doesn't really work like that....

Can you give an example what you would want to do here ?

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

select

case $a = 1

#include "script1.au3"

case $a = 2

#include "script2.au3"

endselect

<{POST_SNAPBACK}>

yes i know this way to make my script works but is there any way to #include $myVariable ?

i know it may not possible, but i would like to confirm au3 script *CANNOT* #include $myVariable.

thx for all.

Link to comment
Share on other sites

Help file

Parameters

filename The filename of the current script to include. Path is optional. This must be a string--it cannot be a variable.

If "..." is used, the filename is taken to be relative to the current script.

If <...> is used the filename is taken to be relative to include library directory (usually C:\Program Files\AutoIt3\Include). The include library contains many pre-written user-functions for you to use!

This must be a string--it cannot be a variable.

Edited by scriptkitty

AutoIt3, the MACGYVER Pocket Knife for computers.

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...