Currently when compiling the Include>code.scp works for the first level of code included, but not for any include commands within that included code. Currently it needs the .scp files to be on that computer or it gives an error.
Would there be a way to have the compile sequence check for and run any includes in the included code?
While on this subject, any way to allow variables into the Include function? Like Include>%Script_Dir%\folder\code.scp
nested Include>
Moderators: Dorian (MJT support), JRL
cwd> then include>
Macro Scheduler already has this capability for compiled scripts with nested includes. Try this:
CWD>%codedir%
Include>code.scp
Does it work?
Gale
CWD>%codedir%
Include>code.scp
Does it work?
Gale
*This post includes a bug description, however I will be posting the bug in the appropriate location for Dev's attention.
Works for when running the script, but not when editing the script after opening it in the Macro Scheduler window. This seems like a bug because it works when editing the file when opening it from the file.
This is however a gimmick around using variables in the Include function, but sounds a lot easier to implement but probably led to the bug above (My guess is the Script_Dir is saved as a special variable for the Include function, but this variable isn't being set correctly when opening a file to edit from the Macro Scheduler window).
I looked into this further and found that you can use this to include file names, in the Script_Dir by using Include>folder\code.scp . I probably didn't notice this feature at all because of the bug I seem to be running into. This seems like it will work out nicely.
However, all of this still doesn't cover nested Includes, but that would probably be pretty hard to do, especially if you were looking at including/excluding code with If/Else commands.
Works for when running the script, but not when editing the script after opening it in the Macro Scheduler window. This seems like a bug because it works when editing the file when opening it from the file.
This is however a gimmick around using variables in the Include function, but sounds a lot easier to implement but probably led to the bug above (My guess is the Script_Dir is saved as a special variable for the Include function, but this variable isn't being set correctly when opening a file to edit from the Macro Scheduler window).
I looked into this further and found that you can use this to include file names, in the Script_Dir by using Include>folder\code.scp . I probably didn't notice this feature at all because of the bug I seem to be running into. This seems like it will work out nicely.
However, all of this still doesn't cover nested Includes, but that would probably be pretty hard to do, especially if you were looking at including/excluding code with If/Else commands.