OnViewChange
Triggers a script to run after you switch views (Form, List, Table) manually or in a script step.
When the script runs
After the event has been processed.
Modes in which the trigger can be used
Browse, Find, and Preview modes.
Result
None.
Originated in 
FileMaker Pro 11.0
Notes
This script trigger will not activate when a window is opened, unless another action after the window is opened causes the view to change.
Related topics 
Setting up script triggers
Setting script triggers for layouts
Setting script triggers for objects