setMacroCommand: Difference between revisions
Jump to navigation
Jump to search
Verisimilar (talk | contribs) m (Macros:Functions:setMacroCommand moved to setMacroCommand) |
Verisimilar (talk | contribs) m (Parameter typo.) |
||
Line 2: | Line 2: | ||
|name=setMacroCommand | |name=setMacroCommand | ||
|trusted=true | |trusted=true | ||
|description | |description= | ||
Sets the command that will be run when the [[Token:Macro Button|Macro Button]] is pressed. Note because of the way the parser interprets values within [] you may have to use the [[Macros:Functions:encode| encode()]] and [[Macros:Functions:decode|decode()]] functions with the string. | Sets the command that will be run when the [[Token:Macro Button|Macro Button]] is pressed. Note because of the way the parser interprets values within [] you may have to use the [[Macros:Functions:encode| encode()]] and [[Macros:Functions:decode|decode()]] functions with the string. | ||
Revision as of 04:17, 9 March 2009
setMacroCommand() Function
Note: This function can only be used in a Trusted Macro
Sets the command that will be run when the Macro Button is pressed. Note because of the way the parser interprets values within [] you may have to use the encode() and decode() functions with the string.
Usage
[h: setMacroCommand(buttonIndex, command)]
Examples
[h: setMacroCommand(1, "[macro('Test@Lib:Test'): '']")]