CALL: Difference between revisions
From Macros Wiki
Jump to navigationJump to search
New page: {{Command|syntax=CALL <macro name>, [<arg 1>, <arg 2>, <arg 3> ( max 10 arguments )] |description=*DESCRPTION* |param1=<macro name>|param1_desc={{macro name}} |param2=[<arg 1>]|param2_des... |
No edit summary |
||
(12 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
{{Command|syntax=CALL <macro name>, [<arg 1>, <arg 2>, <arg 3> ( max 10 arguments )] | [[:Category:Language|{{Up}}]] | ||
|description= | |||
{{Command|syntax=[[Image:call.png|right|CALL]]CALL <macro name>, [<arg 1>, <arg 2>, <arg 3> ( max 10 arguments )] | |||
|description=:Call another macro file from within a macro. Once processing of the called macro is complete,<br> | |||
:control will pass back to the macro from which it was called and processing will continue from the line after the macro call. | |||
|param1=<macro name>|param1_desc={{macro name}} | |param1=<macro name>|param1_desc={{macro name}} | ||
|param2=[<arg 1>]|param2_desc={{arg 1}} | |param2=[<arg 1>]|param2_desc={{arg 1}} | ||
|param3=[<arg 2>]|param3_desc={{arg | |param3=[<arg 2>]|param3_desc={{arg 1}} | ||
|param4=[<arg 3>]|param4_desc={{arg | |param4=[<arg 3>]|param4_desc={{arg 1}} | ||
<br> | |||
:You can use between zero and 10 arguments. | |||
}} | }} | ||
===Example=== | ===Example=== | ||
: | :CALL "line.mac" r1, q7, tt | ||
:For an example macro see [[Modify_Op_Path]] [[Get_Op_Tool_Path]] [[Global_Local]] | |||
[[Category:Language]] | [[Category:Language]] |
Latest revision as of 00:08, 15 January 2011
Command
- Call another macro file from within a macro. Once processing of the called macro is complete,
- control will pass back to the macro from which it was called and processing will continue from the line after the macro call.
Parameters
- <macro name>
- Name of the macro file, must be in double quotes.
- [<arg 1>]
- A value to be passed to another macro, or a variable to receive a value passed back from the macro that is called.
- [<arg 2>]
- A value to be passed to another macro, or a variable to receive a value passed back from the macro that is called.
- [<arg 3>]
- A value to be passed to another macro, or a variable to receive a value passed back from the macro that is called.
- You can use between zero and 10 arguments.
Example
- CALL "line.mac" r1, q7, tt
- For an example macro see Modify_Op_Path Get_Op_Tool_Path Global_Local