Anthem.DataList Class Reference

An updatable data bound list control that displays items using templates. More...

Inheritance diagram for Anthem.DataList:

Anthem.IUpdatableControl Anthem.ICallBackContainerControl List of all members.

Public Member Functions

override void RenderControl (HtmlTextWriter writer)
 Renders the control contents. Anthem.Manager will determine if the control is rendered on the client.

Protected Member Functions

override void OnCancelCommand (ASP.DataListCommandEventArgs e)
 Excecutes System.Web.UI.WebControls.DataList.OnCancelCommand, then sets UpdateAfterCallBack to true.
override void OnDeleteCommand (System.Web.UI.WebControls.DataListCommandEventArgs e)
 Excecutes System.Web.UI.WebControls.DataList.OnDeleteCommand, then sets UpdateAfterCallBack to true.
override void OnEditCommand (System.Web.UI.WebControls.DataListCommandEventArgs e)
 Excecutes System.Web.UI.WebControls.DataList.OnEditCommand, then sets UpdateAfterCallBack to true.
override void OnItemCommand (System.Web.UI.WebControls.DataListCommandEventArgs e)
 Excecutes System.Web.UI.WebControls.DataList.OnItemCommand, then sets UpdateAfterCallBack to true.
override void OnSelectedIndexChanged (EventArgs e)
 Excecutes System.Web.UI.WebControls.BaseDataList.OnSelectedIndexChanged, then sets UpdateAfterCallBack to true.
override void OnUpdateCommand (System.Web.UI.WebControls.DataListCommandEventArgs e)
 Excecutes System.Web.UI.WebControls.DataList.OnUpdateCommand, then sets UpdateAfterCallBack to true.
override void Render (HtmlTextWriter writer)
 Renders the control inside of a <div> element to the specified HTML writer.
override void OnLoad (EventArgs e)
 Raises the System.Web.UI.Control.Load event and registers this control with Anthem.Manager.

Properties

[Category("Anthem")][DefaultValue("")][Description("The javascript
function to call on the client
if the callback is cancelled.")]
virtual string 
CallBackCancelledFunction [get, set]
 Gets or sets the javascript function to execute on the client if the callback is cancelled. See PreCallBackFunction.
[Category("Anthem")][DefaultValue(true)][Description("True
if this control uses callbacks
instead of postbacks to post
data to the server.")] virtual
bool 
EnableCallBack [get, set]
 Gets or sets a value indicating whether the control uses callbacks instead of postbacks to post data to the server.
[Category("Anthem")][DefaultValue(true)][Description("True
if this control is enabled
on the client during callbacks.")]
virtual bool 
EnabledDuringCallBack [get, set]
 Gets or sets a value indicating whether the control is enabled on the client during callbacks.
[Category("Anthem")][DefaultValue("")][Description("The javascript
function to call on the client
after the callback response
is received.")] virtual string 
PostCallBackFunction [get, set]
 Gets or sets the javascript function to execute on the client after the callback response is received.
[Category("Anthem")][DefaultValue("")][Description("The javascript
function to call on the client
before the callback is made.")]
virtual string 
PreCallBackFunction [get, set]
 Gets or sets the javascript function to execute on the client before the callback is made.
[Category("Anthem")][DefaultValue("")][Description("The text
to display during the callback.")]
virtual string 
TextDuringCallBack [get, set]
 Gets or sets the text to display on the client during the callback.
[Category("Anthem")][DefaultValue(true)][Description("True
if this control should convert
child control postbacks into
callbacks.")] virtual bool 
AddCallBacks [get, set]
 Gets or sets a value indicating whether the control should convert child control postbacks into callbacks.
[Category("Anthem")][DefaultValue(false)][Description("True
if this control should be
updated after each callback.")]
virtual bool 
AutoUpdateAfterCallBack [get, set]
 Gets or sets a value indicating whether the control should be updated after each callback. Also see UpdateAfterCallBack.
[Browsable(false)][DefaultValue(false)] virtual bool UpdateAfterCallBack [get, set]
 Gets or sets a value which indicates whether the control should be updated after the current callback. Also see AutoUpdateAfterCallBack.
override bool Visible [get, set]
 Overrides the Visible property so that Anthem.Manager can track the visibility.

Detailed Description

An updatable data bound list control that displays items using templates.

Builtin commands (Edit, Delete, etc.) will use callbacks if EnableCallBack is true. Child controls will use callbacks if AddCallBacks is true.

Definition at line 18 of file DataList.cs.


Member Function Documentation

override void Anthem.DataList.OnCancelCommand ( ASP.DataListCommandEventArgs  e  )  [protected]

Excecutes System.Web.UI.WebControls.DataList.OnCancelCommand, then sets UpdateAfterCallBack to true.

Definition at line 26 of file DataList.cs.

override void Anthem.DataList.OnDeleteCommand ( System.Web.UI.WebControls.DataListCommandEventArgs  e  )  [protected]

Excecutes System.Web.UI.WebControls.DataList.OnDeleteCommand, then sets UpdateAfterCallBack to true.

Definition at line 36 of file DataList.cs.

override void Anthem.DataList.OnEditCommand ( System.Web.UI.WebControls.DataListCommandEventArgs  e  )  [protected]

Excecutes System.Web.UI.WebControls.DataList.OnEditCommand, then sets UpdateAfterCallBack to true.

Definition at line 46 of file DataList.cs.

override void Anthem.DataList.OnItemCommand ( System.Web.UI.WebControls.DataListCommandEventArgs  e  )  [protected]

Excecutes System.Web.UI.WebControls.DataList.OnItemCommand, then sets UpdateAfterCallBack to true.

Definition at line 56 of file DataList.cs.

override void Anthem.DataList.OnSelectedIndexChanged ( EventArgs  e  )  [protected]

Excecutes System.Web.UI.WebControls.BaseDataList.OnSelectedIndexChanged, then sets UpdateAfterCallBack to true.

Definition at line 66 of file DataList.cs.

override void Anthem.DataList.OnUpdateCommand ( System.Web.UI.WebControls.DataListCommandEventArgs  e  )  [protected]

Excecutes System.Web.UI.WebControls.DataList.OnUpdateCommand, then sets UpdateAfterCallBack to true.

Definition at line 76 of file DataList.cs.

override void Anthem.DataList.Render ( HtmlTextWriter  writer  )  [protected]

Renders the control inside of a <div> element to the specified HTML writer.

Parameters:
writer A System.Web.UI.HtmlTextWriter that contains the output stream to render on the client.

Definition at line 87 of file DataList.cs.

override void Anthem.DataList.OnLoad ( EventArgs  e  )  [protected]

Raises the System.Web.UI.Control.Load event and registers this control with Anthem.Manager.

Parameters:
e A System.EventArgs that contains the event data.

Definition at line 387 of file DataList.cs.

override void Anthem.DataList.RenderControl ( HtmlTextWriter  writer  ) 

Renders the control contents. Anthem.Manager will determine if the control is rendered on the client.

Parameters:
writer A System.Web.UI.HtmlTextWriter that contains the output stream to render on the client.

Definition at line 399 of file DataList.cs.


Property Documentation

[Category("Anthem")][DefaultValue("")][Description("The javascript function to call on the client if the callback is cancelled.")] virtual string Anthem.DataList.CallBackCancelledFunction [get, set]

Gets or sets the javascript function to execute on the client if the callback is cancelled. See PreCallBackFunction.

Definition at line 126 of file DataList.cs.

Referenced by Anthem.DataList.Render().

[Category("Anthem")][DefaultValue(true)][Description("True if this control uses callbacks instead of postbacks to post data to the server.")] virtual bool Anthem.DataList.EnableCallBack [get, set]

Gets or sets a value indicating whether the control uses callbacks instead of postbacks to post data to the server.

true if the the control uses callbacks; otherwise, false. The default is true.

Definition at line 152 of file DataList.cs.

Referenced by Anthem.DataList.Render().

[Category("Anthem")][DefaultValue(true)][Description("True if this control is enabled on the client during callbacks.")] virtual bool Anthem.DataList.EnabledDuringCallBack [get, set]

Gets or sets a value indicating whether the control is enabled on the client during callbacks.

true if the the control is enabled; otherwise, false. The default is true.

Not all HTML elements support this property.

Definition at line 179 of file DataList.cs.

Referenced by Anthem.DataList.Render().

[Category("Anthem")][DefaultValue("")][Description("The javascript function to call on the client after the callback response is received.")] virtual string Anthem.DataList.PostCallBackFunction [get, set]

Gets or sets the javascript function to execute on the client after the callback response is received.

The callback response is passed into the PostCallBackFunction as the one and only parameter.

            function AfterCallBack(result) {
              if (result.error != null &amp;&amp; result.error.length &gt; 0) {
                alert(result.error);
              }
            }

Definition at line 215 of file DataList.cs.

Referenced by Anthem.DataList.Render().

[Category("Anthem")][DefaultValue("")][Description("The javascript function to call on the client before the callback is made.")] virtual string Anthem.DataList.PreCallBackFunction [get, set]

Gets or sets the javascript function to execute on the client before the callback is made.

The function should return false on the client to cancel the callback.

Definition at line 240 of file DataList.cs.

Referenced by Anthem.DataList.Render().

[Category("Anthem")][DefaultValue("")][Description("The text to display during the callback.")] virtual string Anthem.DataList.TextDuringCallBack [get, set]

Gets or sets the text to display on the client during the callback.

If the HTML element that invoked the callback has a text value (such as <input type="button" value="Run">) then the text of the element is updated during the callback, otherwise the associated <label> text is updated during the callback. If the element does not have a text value, and if there is no associated <label>, then this property is ignored.

Definition at line 268 of file DataList.cs.

Referenced by Anthem.DataList.Render().

[Category("Anthem")][DefaultValue(true)][Description("True if this control should convert child control postbacks into callbacks.")] virtual bool Anthem.DataList.AddCallBacks [get, set]

Gets or sets a value indicating whether the control should convert child control postbacks into callbacks.

true if the control should convert child control postbacks to callbacks; otherwise, false. The default is true.

Only controls that Anthem.Manager recognizes will be converted.

Implements Anthem.ICallBackContainerControl.

Definition at line 303 of file DataList.cs.

Referenced by Anthem.DataList.Render().

[Category("Anthem")][DefaultValue(false)][Description("True if this control should be updated after each callback.")] virtual bool Anthem.DataList.AutoUpdateAfterCallBack [get, set]

Gets or sets a value indicating whether the control should be updated after each callback. Also see UpdateAfterCallBack.

true if the the control should be updated; otherwise, false. The default is false.

            &lt;anthem:Label id="label" runat="server" AutoUpdateAfterCallBack="true" /&gt;

Implements Anthem.IUpdatableControl.

Definition at line 339 of file DataList.cs.

[Browsable(false)][DefaultValue(false)] virtual bool Anthem.DataList.UpdateAfterCallBack [get, set]

Gets or sets a value which indicates whether the control should be updated after the current callback. Also see AutoUpdateAfterCallBack.

true if the the control should be updated; otherwise, false. The default is false.

            this.Label = "Count = " + count;
            this.Label.UpdateAfterCallBack = true;

Implements Anthem.IUpdatableControl.

Definition at line 374 of file DataList.cs.

override bool Anthem.DataList.Visible [get, set]

Overrides the Visible property so that Anthem.Manager can track the visibility.

true if the control is rendered on the client; otherwise false. The default is true.

Definition at line 414 of file DataList.cs.

Referenced by Anthem.DataList.Render().


The documentation for this class was generated from the following file:
Generated on Wed Mar 14 23:50:40 2007 for Anthem by  doxygen 1.5.1-p1