Macros & Global variables

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 2 and 3.

Moderators: Benj, Mods

Post Reply
Ron
Posts: 225
Joined: Wed Apr 11, 2007 6:15 pm
Has thanked: 2 times

Macros & Global variables

Post by Ron »

Hi,


If you want to "use" a global variable in a macro MUST the global variable be passed into the macro as a parameter or can it simply be hard coded in the macro?

I do not want my main program to have losts of loops and jumps in it. I would prefer it to be made up of mainly macro calls.

My situation...

Main program calls MACRO_1 - MACRO_1 loops many (12) times calling MACRO_2 with each loop. Macro 1 is hard coded to input a different Global variable with each loop into Macro 2 as a parameter. These gloabl variables that are hard coded in Macro_1 were not passed as paramaters from the MAIN program.

back to my question at top.....


Thanks

Ron

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: Macros & Global variables

Post by Benj »

Hi Ron

If you firstly select your macro in question then click on Macro -> Edit. This will give you a dialogue where you can specify parameter variables or variables local to the macro.

Hope this helps.

Post Reply