If you set this to Conditional (the default is Always), then updates to
the rendering of the markup will occur only when a trigger is hit. The Triggers tag contains
the collection of trigger definitions. In Visual Studio 2005, there is a designer-based
Trigger Collections Editor (accessed by clicking on the Triggers Collection property in the
property box for the UpdatePanel) that can be used to view and edit triggers within an
UpdatePanel as shown in Figure 5-9.
Figure 5-9. UpdatePanelTrigger Collections Editor in Visual Studio 200
There are two types of triggers supported within the
tag:
AsyncPostBackTrigger and PostBackTrigger. You can actually use these triggers for
controls that are not within the UpdatePanel. The two tags differ only in the fact that
AsyncPostBackTrigger, as the name suggests, can handle asynchronous postback when
the trigger is raised. It also has an additional property called EventName, which allows you
to specify the event name of the target control responsible for initiating the update.
You define an AsyncPostBackTrigger trigger with an associated control (specified by
ControlID) and an event name (specified by the EventName).
Pages:
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174