Binding to Large Database (Server Mode)
The Grid View control supports binding to data in the server mode using the EntityServerModeDataSource component. In this mode, the Grid View loads only the minimum amount of data required for display on screen and delegates all data processing (such as grouping and sorting) to the database server. This technique significantly reduces the application's response time when working with large data sets.
: 100ms
Drag a column header here to group by that column
| | | | |
Bert Parkins | Email Attachments. Is it possible to add multiple attachments? I haven't found a way to do this. | 4/3/2016 | | 5.74 KB |
Tom Hamlett | Payables Due Calculator is ready for testing. | 3/8/2016 | | 45.65 KB |
Tom Hamlett | Email Attachments. Is it possible to add multiple attachments? I haven't found a way to do this. | 2/26/2016 | | 180.06 KB |
Ray Shipman | Integrating Developer Express MasterView control into an Accounting System. | 2/21/2016 | | 200.6 KB |
Tom Hamlett | Email System. What library are we going to use? | 3/31/2016 | | 252.16 KB |
Dave Murrel | Main Menu: Add a File menu. File menu item is missing. | 3/12/2016 | | 270.49 KB |
Ryan Fischer | Receivables Calculator. Where can I find the complete specs? | 3/5/2016 | | 209.34 KB |
Carl Lucas | Payables Due Calculator is ready for testing. | 2/28/2016 | | 189.17 KB |
Brad Barnes | Receivables Calculator. Where can I find the complete specs? | 3/9/2016 | | 141.5 KB |
Carl Lucas | Drag & Drop operations are not available in the scheduler module. | 4/6/2016 | | 226.69 KB |
<dx:BootstrapGridView ID="GridViewServerMode" runat="server" DataSourceID="EntityServerModeDataSource" KeyFieldName="ID" AutoGenerateColumns="False"
OnCustomColumnDisplayText="GridViewServerMode_CustomColumnDisplayText" OnSummaryDisplayText="GridViewServerMode_SummaryDisplayText">
<Columns>
<dx:BootstrapGridViewTextColumn FieldName="From" />
<dx:BootstrapGridViewTextColumn FieldName="Subject" />
<dx:BootstrapGridViewDateColumn FieldName="Sent" Width="220px" />
<dx:BootstrapGridViewCheckColumn Caption="Has Attachments" FieldName="HasAttachment" Width="150px" />
<dx:BootstrapGridViewTextColumn FieldName="Size">
<Settings AllowAutoFilter="False" />
</dx:BootstrapGridViewTextColumn>
</Columns>
<SettingsPager NumericButtonCount="4">
<PageSizeItemSettings Visible="true" Items="10, 20, 50" />
</SettingsPager>
<TotalSummary>
<dx:ASPxSummaryItem FieldName="Size" SummaryType="Sum" />
</TotalSummary>
<GroupSummary>
<dx:ASPxSummaryItem SummaryType="Count" />
</GroupSummary>
<Settings ShowGroupPanel="True" ShowFooter="True" ShowFilterRow="true" ShowFilterRowMenu="true"/>
</dx:BootstrapGridView>
<dx:EntityServerModeDataSource ID="EntityServerModeDataSource" runat="server"
ContextTypeName="DevExpress.Web.Demos.LargeDatabaseContext" TableName="Emails" />
protected void GridViewServerMode_CustomColumnDisplayText(object sender, ASPxGridViewColumnDisplayTextEventArgs e) {
if(e.Column.FieldName == "Size")
e.DisplayText = FormatByteSize(e.Value);
}
protected void GridViewServerMode_SummaryDisplayText(object sender, ASPxGridViewSummaryDisplayTextEventArgs e) {
if(e.Item.FieldName == "Size")
e.Text = string.Format("Sum = {0}", FormatByteSize(e.Value));
}
protected string FormatByteSize(object value) {
string[] sizes = { "B", "KB", "MB", "GB" };
double len = Convert.ToDouble(value);
int order = 0;
while(len >= 1024 && ++order < sizes.Length)
len = len / 1024;
return String.Format("{0:0.##} {1}", len, sizes[order]);
}
Screen Size
Color Themes
Demo QR Code