mapp Script, introduced as a premium feature in mapp View V6.3, enables the creation of advanced event bindings in HMI applications using a JavaScript-like language. It complements the existing event-binding system and provides developers with direct access to internal BRease functions while supporting standard programming structures like loops and conditional statements.
Use Cases and Performance Benefits
Traditional event bindings in mapp View can become limiting when implementing complex logic. mapp Script addresses this by enabling:
-
Complex event sequences through code rather than configuration.
-
Client-side execution, resulting in faster response times.
-
Direct access to BRease functions and system variables.
-
Support for loops, conditions, and other native programming constructs.
Cross-compilation, introduced in mapp View V6.2, already optimized existing event bindings by converting them into native JavaScript. However, mapp Script allows developers to go one step further by writing and controlling that JavaScript themselves.
Performance Comparison:
| Action | Classic Binding | JavaScript (mapp Script) | Gain |
|---|---|---|---|
| MouseDown β LoadContent | 175 ms | 3.5 ms | β171.5 ms |
| MouseDown β ContentLoaded | 500 ms | 300 ms | β200 ms |
Performance depends heavily on the type of actions executed.
Compound Widgets & Maintainability
Compound widgets often accumulate large configurations. A real-world example:
Original ButtonBar widget: ~1500 lines of code
Using mapp Script: 101 lines of clear, readable, and maintainable script.
Advantages include:
-
Inline comments for documentation.
-
Use of constants and functions to reduce duplication.
-
Option to combine event-bindings with scripts for optimal balance.
Tip: Use cross-compilation for initial optimization, then apply mapp Script for full control and maximum performance.
What Can You Interact With?
Using mapp Script, developers can programmatically interact with:
-
Widget events and actions
-
OPC UA variables
-
Session variables
-
ClientSystem functions and timers
Licensing & Availability
-
Available from mapp View V6.3
-
Requires a mapp View license
-
One mapp Script license is required per target system
-
Part number:
1TC6MPVIEW SCR .20
Roadmap and Future Outlook
-
Cross-compilation (free): Available since mapp View V6.2
-
mapp Script (premium): Released with mapp View V6.3
Further Resources
- MappScript in Automation Studio Help
- Samples of using JS in mappView
- JavaScript tutorials
Final Thoughts
mapp Script bridges the gap between configuration and coding, offering a performance-optimized, scalable, and developer-friendly way to create dynamic HMI interactions. Whether youβre looking to simplify complex compound widgets or boost runtime efficiency, mapp Script provides the tools and flexibility needed for modern HMI applications.




