aspnetbootstrap-devexpress-dot-web-dot-bootstrap-7716b928.md
Represents a panel control that acts as a container for other controls and allows its content to be updated, via callbacks.
Namespace : DevExpress.Web.Bootstrap
Assembly : DevExpress.Web.Bootstrap.v25.2.dll
NuGet Package : DevExpress.Web.Bootstrap
[DXClientDocumentationProviderWeb("BootstrapCallbackPanel")]
[ToolboxBitmap(typeof(BootstrapToolboxBitmapAccess), "Bitmaps256.BootstrapCallbackPanel.bmp")]
[ToolboxTabName("DX.25.2: Bootstrap Controls")]
public class BootstrapCallbackPanel :
ASPxPanelContainerBase,
ISimpleRenderControl
<ToolboxTabName("DX.25.2: Bootstrap Controls")>
<DXClientDocumentationProviderWeb("BootstrapCallbackPanel")>
<ToolboxBitmap(GetType(BootstrapToolboxBitmapAccess), "Bitmaps256.BootstrapCallbackPanel.bmp")>
Public Class BootstrapCallbackPanel
Inherits ASPxPanelContainerBase
Implements ISimpleRenderControl
The BootstrapCallbackPanel control represents a container area whose content can be updated using an AJAX-based callback technology. The collection of the BootstrapCallbackPanel ‘s child controls can be accessed via the ASPxPanelContainerBase.Controls property.
The BootstrapCallbackPanel control implements a comprehensive client-side and server-side functionality to enable updating its content on demand via callbacks. The client-side object model contains the client object for the BootstrapCallbackPanel control (BootstrapClientCallbackPanel), its method requires sending a callback to the server (BootstrapClientCallbackPanel.PerformCallback), and methods allowing specific client operations to be performed when a callback sends to, and comes from the server side (BootstrapClientCallbackPanel.BeginCallback and BootstrapClientCallbackPanel.EndCallback). A handler for the available client-side events can be assigned by using the control’s BootstrapCallbackPanel.ClientSideEvents property. An instance of the BootstrapClientCallbackPanel object can be easily identified on the client by using the client programmatic identifier set via the ASPxPanelBase.ClientInstanceName property.
The required server-side processing of a callback sent from the client side by using the BootstrapClientCallbackPanel.PerformCallback method can be performed in a handler of the control’s server-side BootstrapCallbackPanel.Callback event.
This example demonstrates the basic functionality of the Callback Panel.
BootstrapCallbackPanel class.ContentCollection array.The image below shows the result:
protected void CallbackPanel_Callback(object sender, DevExpress.Web.CallbackEventArgsBase e) {
if(!string.IsNullOrEmpty(e.Parameter))
passedInfo.InnerText = "Passed information: \"" + e.Parameter + "\"";
}
function onUpdateClick(s, e) {
callbackPanel.PerformCallback("caused on the button click");
}
<dx:BootstrapCallbackPanel runat="server" ClientInstanceName="callbackPanel" OnCallback="CallbackPanel_Callback">
<ContentCollection>
<dx:ContentControl>
<div class="card">
<div class="card-body">
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse sem lorem, rutrum at tincidunt aliquam, vulputate sit amet tellus. In hac habitasse platea dictumst. Morbi in dui a massa volutpat tristique. Aenean ultrices, elit ac commodo vestibulum, nisl neque pharetra est, id egestas neque leo dignissim augue. Vestibulum sodales metus at est maximus dictum. Quisque cursus felis id nisi auctor, volutpat imperdiet neque feugiat. Sed aliquet elit sem, ut vulputate lectus ultricies sit amet.</p>
<p><span class="badge badge-info"><%= IsCallback ? "The content was updated at " + DateTime.Now.ToLongTimeString() : "" %></span></p>
<small runat="server" id="passedInfo"></small>
</div>
</div>
</dx:ContentControl>
</ContentCollection>
</dx:BootstrapCallbackPanel>
<dx:BootstrapButton Text="Update" AutoPostBack="false" UseSubmitBehavior="false" runat="server">
<ClientSideEvents Click="onUpdateClick" />
</dx:BootstrapButton>
Object Control WebControl ASPxWebControlBase ASPxWebControl ASPxPanelContainerBase BootstrapCallbackPanel
See Also