Send a Variable from KLWP to KWGT #
You can share data between Kustom apps using the Send Data action in a KLWP flow and the $br()
function. This allows you to trigger changes or display dynamic data in, for example, KWGT directly from KLWP.
KLWP Setup #
- Create a new Flow in KLWP.
- Add a Trigger (e.g., on touch, time, or event).
- Add a Send Data action to the flow.
- In the Send Data action:
- Set Target to
KWGT
- Set Variable Name to
foo
- (Optional) Set the value as needed, for example
Hello KWGT!
- Set Target to
KWGT Setup #
Add a new Text item in your KWGT widget.
Set the formula to:
$br(klwp, foo)$
This will display the value of the variable named foo sent from KLWP.
Result #
Every time the flow in KLWP is triggered, the value of the variable foo will update in the KWGT widget. This is useful for syncing animations, time, or any custom variable between the two.