wifinigel.MikrotikScripting/scripts/ch9-05-use-global-func.rsc
2023-01-19 21:27:15 +00:00

15 lines
472 B
Text

# filename: ch9-05-use-global-func.rsc
# declare the name of the global function we wish to use
# to make it available in our script
:global RemoveSpaceFunc;
# creates a string that contains spaces
:local StringWithSpaces "txBroadcast = 201";
# print original string
:put ("String with spaces: $StringWithSpaces");
# print string that is modified by function
:local StringNoSpaces [$RemoveSpaceFunc $StringWithSpaces];
:put ("String with no spaces: $StringNoSpaces");