isExternalMacroAccessAllowed: Difference between revisions

From RPTools Wiki
Jump to navigation Jump to search
(Created page with "{{MacroFunction |name= isExternalMacroAccessAllowed |version=1.5.0 |description= Returns {{true}} if the client is configured to allow external macro access (see '''Allow Exte...")
 
No edit summary
 
(10 intermediate revisions by 2 users not shown)
Line 3: Line 3:
|version=1.5.0
|version=1.5.0
|description=
|description=
Returns {{true}} if the client is configured to allow external macro access (see '''Allow External Macro Access''' in MapTool Preferences).  When enabled, this allows the use of other macro functions such as {{func|exportData}}.
Returns {{true}} if the client is configured to allow external macro access (see '''[[MapTool_Preferences#Macro Permissions|Allow External Macro Access]]''' in [[MapTool Preferences]]).  When enabled, this allows the use of other macro functions such as {{func|exportData}}.


|usage=
|usage=
<source lang="mtmacro" line>
<syntaxhighlight lang="mtmacro" line>
isExternalMacroAccessAllowed()
isExternalMacroAccessAllowed()
</source>
</syntaxhighlight>


|examples=
|examples=
'''1. Test to see if the current client can access external resources from macros.'''
'''1. Test to see if the current client can access external resources from macros.'''


<source lang="mtmacro" line>
<syntaxhighlight lang="mtmacro" line>
This client has external access [r,if(isExternalMacroAccessAllowed()): "Enabled"; "Disabled"]
This client has external access [r,if(isExternalMacroAccessAllowed()): "Enabled"; "Disabled"]
</source>
</syntaxhighlight>


|changes=
|changes=
}}
}}
[[Category:Permission Function]]
[[Category:Permission Function]]

Latest revision as of 20:21, 15 March 2023

isExternalMacroAccessAllowed() Function

Introduced in version 1.5.0
Returns true(1) if the client is configured to allow external macro access (see Allow External Macro Access in MapTool Preferences). When enabled, this allows the use of other macro functions such as exportData().

Usage

isExternalMacroAccessAllowed()

Examples

1. Test to see if the current client can access external resources from macros.
This client has external access [r,if(isExternalMacroAccessAllowed()): "Enabled"; "Disabled"]