Information Technology Reference
In-Depth Information
Adding an outlet
The handler should have a visible effect. In this example, it changes the label text. To do this, we need to con-
nect the label to an outlet so we can read and set its properties with code.
Select the label, as shown in Figure 7.27. The Connections Inspector changes to show a Referencing Outlet sub-
pane and a Referencing Outlet Collections subpane. Ignore the Collections option, and drag a line from the
circle next to New Referencing Outlet. Add the outlet below the curly brackets.
CAUTION
You can also add an outlet between the curly brackets, but this has a different and less useful effect, as described
below.
FIGURE 7.27
When you add an outlet, a floating location line and a tool tip appear to confirm the operation. Always add an
outlet below the curly brackets.
Search WWH ::




Custom Search