Active Controls (AJAX enabled Controls)

Active controls extends standard PRADO controls adding the ability to automatically update themselves on callbacks without the need of ad-hoc javascript calls. See the Introduction for a quick overview of the concept behind active controls (AJAX enabled controls). Most active controls have a property of ActiveControl and a sub-property ClientSide that provides many properties to customize the controls. The CallbackClient property of the TPage class provides many methods to update and alter the client-side content during a callback request. Active controls is reliant on a collection of javascript classes.

For a quick demo of active controls, try the TActiveButton control. See also the later part of the Currency Converter tutorial for a more in depth example.

Standard Active Controls

  • TActiveButton represents a click button on a Web page. It can be used to trigger a callback request.
  • TActiveCheckBox represents a checkbox on a Web page. It can be used to collect two-state user input and can trigger a callback request.
  • TActiveCustomValidator validates a particular control using a callback request.
  • TActiveDatePicker adds a date picker that permits the suer to choose a date.
  • TActiveFileUpload displays a file upload field on a page and uses an iframe to permit handling of the file upload in a callback.
  • TActiveHiddenField displays a hidden input field that can be changed upon callback.
  • TActiveHyperLink represents a hyperlink on a Web page.
  • TActiveImage represents an image on a Web page.
  • TActiveImageButton represents a click button that has an image as the background. It is can be used to trigger a callback request.
  • TActiveLabel represents a label on a Web page. The label can be customized via various CSS attributes.
  • TActiveLinkButton represents a hyperlink that can perform a callback request.
  • TActiveMultiView represents a container for a group of TView controls, each of which is container for other controls. At any time, at most one TView is visible. It's the active counterpart of TMultiView.
  • TActivePanel represents a container for other controls on a Web page. In HTML, it is displayed as a <div> element. The panel's contents can be replaced during a callback request.
  • TActivePager generates UI that allows users to interactively specify which page of data to be displayed in a data-bound control.
  • TActiveRadioButton represents a radiobutton on a Web page. It is mainly used in a group from which users make a choice. It can be used to perform a callback request.
  • TActiveRatingList is an EXPERIMENTAL class that displays clickable images that represent a TRadioButtonList.
  • TActiveTextBox represents a text input field on a Web page. It can collect single-line, multi-line or password text input from users. It can be used to perform a callback request.

Active List Controls

  • TActiveCheckBoxList displays a list of checkboxes on a Web page and each checkbox can trigger a callback request.
  • TActiveDropDownList displays a dropdown list box that allows users to select a single option from a few prespecified ones. It can be used to perform a callback request.
  • TActiveListBox displays a list box that allows single or multiple selection. It can be used to perform a callback request.
  • TActiveRadioButtonList is similar to TActiveCheckBoxList in every aspect except that each TActiveRadioButtonList displays a group of radiobuttons. Each radio button can perform a callback request.

Active Data Controls

  • TActiveDataList is used to display or modify a list of data items. It is the active counterpart to the original TDataList control.
  • TActiveDataGrid displays data in a tabular format with rows and columns. It is the active counterpart to the original TDataGrid control.
  • TActiveRepeater displays its content defined in templates repeatedly based on the given data. It is the active counterpart to the original TRepeater control.

Extended Active Controls

  • TAutoComplete extends TActiveTextBox to offer text completion suggestions.
  • TCallback a generic control that can perform callback requests.
  • TEventTriggeredCallback triggers a callback request based on HTML DOM events.
  • TInPlaceTextBox represents a label that can be edited by clicked.
  • TTimeTriggeredCallback triggers a callback request based on time elapsed.
  • TValueTriggeredCallback monitors (using a timer) an attribute of an HTML element and triggers a callback request when the attribute value changes.
  • TDropContainer & TDraggable represents drag and drop containers. The former will make its child controls "draggable" while the latter will raise a callback when a draggable control is dropped on it.

Active Control Abilities

The following table shows the Active Controls that can trigger a callback event and whether the control will raise a PostBack event if Javascript was disabled on the client's browser.

Control Name Triggers Callback Falls back to PostBack
TActiveButton Yes Yes
TActiveCheckBox Yes Yes
TActiveCustomValidator Yes Yes
TActiveHyperLink NoYes
TActiveImage NoYes
TActiveImageButton YesYes
TActiveLabel NoYes
TActiveLinkButton YesNo
TActivePanel NoYes
TActiveRadioButton YesYes
TActiveTextBox YesYes
TCallbackOptions NoN/A
TActiveCheckBoxList YesYes
TActiveDropDownList YesYes
TActiveListBox YesYes
TActiveRadioButtonList YesYes
TAutoComplete Yes No
TCallback YesNo
TEventTriggeredCallback YesNo
TInPlaceTextBox YesNo
TTimeTriggeredCallback YesNo
TValueTriggeredCallback YesNo
TDropContainer YesNo
TDraggable NoNo