See what a connection is
Connect parts to add function to my applicationConnect parts to add function to my applicationNo tip for this topicNo example for this topicDraw a connection between partsDraw a connection between parts
Once you add user interface parts to your application, to add function to your application you need to connect the parts.
Each part has attributes, events, and actions. When you connect parts, you connect one part's attribute, event, or action to another part's attribute, event, or action.
For example, suppose the user interface for your application has a push button Show, a text field that displays "Initial text" when you open the application, and some Smalltalk code that returns "Later text".
If you press Test to open your application's window, and then press its Show button, nothing happens.
To make your application run the Smalltalk code (or script) and display "Later text" in the text field when you press Show, you must add the connections shown below:
Window with event-to-action connection
The green line is an event-to-action connection. It connects the push button's clicked event to the text field's object action.
The blue line is an attribute-to-script connection. It connects the event-to-action connection's value attribute to the Smalltalk code.
This might seem complex now. But it only takes a few seconds to make the connections. And, once you've tried different types of connections, it becomes straightforward.
Last modified date: 08/08/2019