Home / AJAX

DynamicPopulate Reference

RSS
Modified on 2010/05/04 17:04 by Stephen Walther Categorized as Uncategorized

DynamicPopulateExtender Server Reference

This extender allows you to dynamically populate the innerHTML of a control based on a web service callback.

DynamicPopulateExtender Server Properties

NameDescription
CacheDynamicResults Whether the results of the dynamic population should be cached and not fetched again after the first load
ClearContentsDuringUpdate Whether or not we should clear the HTML contents of the target element when an update begins
ContextKey An key that you can pass to the web service call, such as an ID. This is optional.
CustomScript A CustomScript can be used to eval a javascript function that will return a string to populate the control. This script method must return a string and will be called instead of the Service or Page method.
PopulateTriggerControlID The ID of a control to trigger the population of the target. The population will be triggered by this controls "click" event.
ServiceMethod The method name of the web service of page method to call.
ServicePath The path of the web service to call, or if this is blank, a page method will be called instead.
UpdatingCssClass A CSS style to apply while the update is in progress

DynamicPopulateExtender Server Methods

NameDescription
CheckIfValid(System.Boolean) Check if the properties have been set correctly
ShouldSerializeServicePath Prevent serialization of the service path if no ServiceMethod was supplied

DynamicPopulateBehavior Client Reference

The DynamicPopulateBehavior replaces the contents of an element with the result of a web service or page method call. The method call returns a string of HTML that is inserted as the children of the target element.

DynamicPopulateBehavior Client Properties

NameDescription
cacheDynamicResultsWhether the results of the dynamic population should be cached and not fetched again after the first load
ClearContentsDuringUpdateWhether the contents of the target should be cleared when an update begins
ContextKeyAn arbitrary string value to be passed to the web method. For example, if the element to be populated is within a data-bound repeater, this could be the ID of the current row.
CustomScriptThe script to invoke instead of calling a Web or Page method. This script must evaluate to a string value.
PopulateTriggerIDName of an element that triggers the population of the target when clicked
ServiceMethodThe name of the method to call on the page or web service
ServicePathThe URL of the web service to call. If the ServicePath is not defined, then we will invoke a PageMethod instead of a web service.
UpdatingCssClassThe CSS class to apply to the target during asynchronous calls

DynamicPopulateBehavior Client Methods

NameDescription
dispose Dispose the behavior
initialize Initialize the behavior
populate Get the dymanic content and use it to populate the target element
raisePopulated Raise the populated event
raisePopulating Raise the populating event
setStyle Set the style of the display

DynamicPopulateBehavior Client Events

NameDescription
populated Add an event handler for the populated event
populating Add an event handler for the populating event