...
| Note |
|---|
WhereScape RED supports the use of keyboard shortcuts—the underlined letter of a menu option. For example, pressing P opens the Properties window of the selected table, pressing D deletes the script metadata, etc. Ensure that the Windows > Control Panel > Ease of Access setting associated with keyboard shortcuts is enabled, to display keyboard shortcuts in RED. Refer to the relevant MS Windows documentation for details. |
| Anchor |
|---|
| _referencing_other_scripts_at_run-time |
|---|
|
...
| | _referencing_other_scripts_at_run-time |
|---|
|
...
Referencing other scripts at run-timeScripts stored in your RED Metadata can be referenced from other Scripts at run-time using token replacement. This is also known as Script Sourcing in RED.
| Anchor |
|---|
| _script_sourcing_token_replacement_format |
|---|
| _script_sourcing_token_replacement_format |
|---|
|
Script Sourcing Token replacement format$WSL_SCRIPT_<your_script_name_in_RED>_CODE$
...
| Code Block |
|---|
|
# Trigger the RED Script Sourcing feature
# Note: This line could also be commented out as the
# presence of the token is all that is required
# for RED to trigger the script to be written to
# the work directory.
path_to_WslPythonCommon = r"$WSL_SCRIPT_WslPythonCommon_CODE$"
# Now we can mportimport the module name
# Note: Python will automatically look for modules in the script run directory.
import WslPythonCommon |
...