Sometimes you may need to use important information you don't want to alter by accident. This macro allows you to manage (create, modify or delete) PROTECTED VARIABLES.
Each PROTECTED VARIABLE content/value is stored in a file located in this internal storage directory:
"MacroDroid /.ProtectedVars"
Every PROTECTED VARIABLE can contain either strings (with whatever characters, including emojis), numerical values (integer or decimal) or mathematical formulas/functions (integrated MD ones only)
To GET the content/value of a PROTECTED VARIABLE (such as a constant), replace the common MD Action "Set Variable" in your macros by the "GetProtectedVar" Action Block call with its parameters (see this Action block for more details).
To CREATE or UPDATE a PROTECTED VARIABLE programmatically, use the "PutProtectedVar" password protected Action Block to avoid erasing or updating a PROTECTED VARIABLE by accident (see this Action block for more details).
HINT: to initiate 3 sample PROTECTED VARIABLES, you can run TstPutProtectedVar macro first. Then run this ProtectedVars macro.
_________________________________________
This macro shows how to call GetProtectedVar Action block to get the content/value of a PROTECTED VARIABLE.
See GetProtectedVar Action block description for further details.
_________________________________________
This macro initiates 3 sample PROTECTED VARIABLES.
For further information, look at explanations in:
• ProtectedVars macro
• PutProtectedVar Action block
Each PROTECTED VARIABLE content/value is stored in a file located in this internal storage directory:
"MacroDroid /.ProtectedVars"
Every PROTECTED VARIABLE can contain either strings (with whatever characters, including emojis), numerical values (integer or decimal) or mathematical formulas/functions (integrated MD ones only)
To GET the content/value of a PROTECTED VARIABLE (such as a constant), replace the common MD Action "Set Variable" in your macros by the "GetProtectedVar" Action Block call with its parameters (see this Action block for more details).
To CREATE or UPDATE a PROTECTED VARIABLE programmatically, use the "PutProtectedVar" password protected Action Block to avoid erasing or updating a PROTECTED VARIABLE by accident (see this Action block for more details).
HINT: to initiate 3 sample PROTECTED VARIABLES, you can run TstPutProtectedVar macro first. Then run this ProtectedVars macro.
_________________________________________
This macro shows how to call GetProtectedVar Action block to get the content/value of a PROTECTED VARIABLE.
See GetProtectedVar Action block description for further details.
_________________________________________
This macro initiates 3 sample PROTECTED VARIABLES.
For further information, look at explanations in:
• ProtectedVars macro
• PutProtectedVar Action block