Page 1 of 1

Macro return value

Posted: Thu Sep 25, 2008 9:28 am
by Kumaran
I have createded a macro in my program. I wanted a byte value to return. How to do? IN macro properties I have selected Byte as return type. Which value it will return? How to define it?

Thanks in advance
Kumaran

Re: Macro return value

Posted: Thu Sep 25, 2008 1:28 pm
by Steve
Add a calculation icon within the macro itself. When you browse the available variables (using the "variables.." button on the edit calculation icon), you will see a variable called something like "myMacro.Return" - this will hold the value that is returned by the macro.

Re: Macro return value

Posted: Thu Sep 25, 2008 4:43 pm
by saschech@gmx.de
Halle Steve
What is the difference between a variables build by me self and the *.Return variables?

Regards wolfgang

Re: Macro return value

Posted: Thu Sep 25, 2008 4:56 pm
by Kumaran
Hello

Thank you

Regards
Kumaran

Re: Macro return value

Posted: Fri Sep 26, 2008 8:35 am
by Steve
Hello Wolfgang,

The "*.return" variable is just a special variable that holds the value to return from the macro (if you have selected it to have a return value in the macro properties). It works like any other variable, but is 'local' to the macro in the same way that "parameters" and "local variables" are.