ASP.NET Team Blog

This Blog


Mehul Harry is the DevExpress Web Program Manager. Follow him on twitter: @Mehulharry

Subscribe (RSS, Email)


Screencast: Enable Server Mode using LINQ (ASPxGridView & XtraGrid)

In a previous post, I showed you how to use the powerful Server mode feature in ASPxGridView and XtraGrid against large datasets. The response to Server mode was so good that we've extended the ways that you can enable it.

You can now use a LINQ provider to work with our .NET grids in Server mode. The latest release, 2008 Volume 1, introduces two new datasources to support LINQ.   LinqServerModeDataSource supports the ASPxGridView and the LinqServerModeSource supports the XtraGrid. To use these datasources against either the ASPxGridView or XtraGrid, try the steps demonstrated in the short screencasts below.

ASPxGridView Screencast


XtraGrid Screencast


The LINQ support in Server mode is bleeding-edge technology which gives you the performance gains for your projects. Check out this cool feature then let me know how you're using LINQ and how you plan to use these new LINQ datasources.

Published Mar 25 2008, 12:01 AM by
Bookmark and Share


Rinat Abdullin


Sorry for the naive questions, but still:

What is the difference between LinqServerModeDataSource LinqServerModeSource?

Are there any performance gains of using new data sources as opposed to XPServerCollectionSource (esp, in the number of roundtrips)? Are there any performance measurements?

Best regards,

Rinat Abdullin

NB for the Web Admins: You can easily bind the RSS feed directly to devexpress domain (just requires minor DNS tweak). Feedburner supports that.

March 25, 2008 5:33 AM

Mehul Harry (DevExpress)

Hello Rinat,

"LinqServerModeDataSource supports the ASPxGridView and the LinqServerModeSource supports the XtraGrid" Smile

As for performance, the server mode is still blazingly fast with the new datasources. I'll see if there are any measurements. Thanks for the tip on the RSS Feed.

March 25, 2008 5:54 AM

Ben Hayat


This would be my first to use LinqServerModeDataSource, and here is my question. As you know, ASP.Net provides LinqDatasource that you can use.

a) Is yours a replacement to the stock LinqDataSource?

b) If yes, can you point out what are the differences?

c) Can we use your DataSource with some of the ASP.Net stock (std) controls that come with VS2008 or should we use yours only for DX products?



March 25, 2008 10:30 AM

Mehul Harry (DevExpress)

Hello Ben,

LinqServerModeDataSource doesn't replace the standard class. It allows you to use an ASPxGridView (or XtraGrid) in server mode with any LINQ data source.

These new datasources can only be used with controls that support the IListServer (server mode) interface.


March 25, 2008 2:34 PM

Ben Hayat

Thanks Mehul!


March 25, 2008 5:16 PM

Kavan Shaban


Will this work for any Linq provider or are the DevEx Linq data sources specific to Linq2Sql.



March 26, 2008 2:28 PM

Scott Cate's WebLog

Today, I ran across the Developer Express ASP.NET blog , where they have several screen casts about using

March 27, 2008 8:01 PM

Community Blogs

Today, I ran across the Developer Express ASP.NET blog , where they have several screen casts about using

March 27, 2008 8:45 PM

Dan Wahlin's WebLog

I'm one of those developers that likes to build things myself mainly because the challenge is fun. 

March 28, 2008 2:38 AM

Mehul Harry (DevExpress)

Hello Kavan,

These new LINQ datasources works with other LINQ providers as well. Support has tested and verified that LINQ to XML works fine.


March 28, 2008 5:00 AM


Can some one sent me the code on Vb for the grid linq as posted in the XtraGrid Screencast

I can not figure out what goes with

Namespace Form1

    Public Partial Class Form1:Form

       Public Form1()


   End Class

March 29, 2008 8:45 PM

Steven Smith

Mehul has a couple of screencasts up on his blog that demonstrate how to use their new LINQ datasource

March 31, 2008 11:15 AM

Mehul Harry (DevExpress)

Hello Boris,

Sure, here you go:

Public Class Form1

    Sub New()


    linqServerModeSource1.QueryableSource = New DataClasses1DataContext().Customers

    End Sub

End Class


April 1, 2008 3:58 PM


In all the excitement of releasing both DXperience v2008 vol1 and our VCL Subscription build 34 on the

April 1, 2008 6:54 PM

.Net World

Mehul has a couple of screencasts up on his blog that demonstrate how to use their new LINQ datasource

April 2, 2008 4:24 PM


Is the new Linq to SQL Data source supporting also Entity Framework

Database Objects

April 7, 2008 4:34 AM

Mehul Harry (DevExpress)

Hi Alex,

Yes, the LINQ support will work any LINQ provider. I believe LINQ to Entities should work as well.


April 15, 2008 2:29 PM

Emanuele Gigli


is it possibile to use LinqServerMode with the PivotGridControl.

it's another control that need to be used too in server mode!

May 9, 2008 11:17 AM

Mehul Harry (DevExpress)

Hi Emanuele,

Unfortunately the ASPxPivotGrid control cannot use the LinqServerModeDataSource. Take a look at the following issue for an explanation:


May 9, 2008 1:44 PM

The ASPx Blog

Check out this 4 minute video on a very useful feature in the 2008 vol 2 release. The video/screencast

July 10, 2008 7:01 PM


Hello Mehul,

in Version 2008.2 it is possible to update data with the Webgrid and the LinqServerModeDataSource - But what's about Winforms? I found no issue to Update Linqdata with the XtraGrid.

Can you please help?

August 4, 2008 10:57 AM

Mehul Harry (DevExpress)

Hello mfe,

About editing XtraGrid with LINQ server mode, please see this question in the support center:

August 4, 2008 2:18 PM

John Secada

the xtragrid video cannot be opened

September 12, 2008 9:59 AM

Mehul Harry (DevExpress)

Hello John,

Thanks for letting me know. Since we moved the new site, some of the links didn't get updated but I've updated this post to point to the correct videos.

September 12, 2008 1:52 PM

The ASPx Blog - Mehul Harry's DevExpress Blog

Check out this in-depth LINQ integration with ASPxGridView video . This video updates an older LINQ video

June 24, 2009 4:02 AM


I am new to DevExpress, so please forgive me if this question is not up to par.

In my project I want to use:

1. The DevExpress GridView

2. Linq to Sql

3. My own custom classes that are mapped to the Linq to Sql Entity Classes

4. LinqServerModeDataSource

I was wondering if there was a way that when I perform an Insert, Update or a Delete that I could execute my own code? For Ex.

When the user tries to Update an item from the Grid, I want to call my ProductManager.Save method.  The ProductManager Save method takes a ProductBO as a parameter. The Save method does the following:

1. Executes Custom Business Validation on the ProductBO.  If the validation fails, it throws an error

2. Maps the ProductBO to the Linq to Sql Product Entity.

3.  Saves the Linq to Sql Product Entity.

Is this possible?  If so how?

Thanks so much.

March 12, 2010 8:54 PM

Mehul Harry (DevExpress)

Hi Michael,

I recommend asking that question in our forums. Also, check out these videos which cover some of those questions:

March 13, 2010 7:08 PM


First,  I would like to say thanks for getting back to me so quickly.  I will check out the videos you mentioned as well as the forums.

My hope is the video's and/or forums will show me a way  to call the insert or update methods that I wrote instead of insert/update calls from the LinqServerModeDataSource.

Thanks so much.

March 15, 2010 9:06 AM

Mehul Harry (DevExpress)


No problem. If you need further help then please contact our support team:

March 15, 2010 2:28 PM


Hi Mehul,

The feature is amaizing. Though how do you think, will it work fine with NHibernate Linq?

I'm asking because we use NHibernate but NHibernate Linq is rather young product and may not support everithing needed or the support may be poor in some parts.

What do you think? How to make sure?

Thanks in advance!

March 25, 2010 1:13 PM

Mehul Harry (DevExpress)

Hi Sabas,

Yes, I love the ServerMode feature as well! :)

As for NHibernate, it seems that there maybe an issue on the NHibernate side, take a look at this:

Hopefully, as LINQ 2 NHibernate matures, these issues will be resolved.


March 25, 2010 2:03 PM


Thanks Mehul for the demo. I'm able to bind the xtraGrid to LinqServerModeSource but I couldn't find the ServerMode property (on DevExpress v2011) and even though I've specified the WaitAnimationOptions = Panel, nothing is being displayed. What are the possible reasons?


August 15, 2012 7:24 AM

Mehul Harry (DevExpress)


You're referring to the WinForms XtraGrid so please post your question here and our support team can help you:


August 15, 2012 12:36 PM

About Mehul Harry (DevExpress)

Mehul Harry is an ASP.NET technical evangelist at Developer Express. You can reach him directly at You can also follow him on Twitter:

Chat is one of the many ways you can contact members of the DevExpress Team.
We are available Monday-Friday between 7:30am and 4:30pm Pacific Time.

If you need additional product information, write to us at or call us at +1 (818) 844-3383


DevExpress engineers feature-complete Presentation Controls, IDE Productivity Tools, Business Application Frameworks, and Reporting Systems for Visual Studio, Delphi, HTML5 or iOS & Android development. Whether using WPF, ASP.NET, WinForms, HTML5 or Windows 10, DevExpress tools help you build and deliver your best in the shortest time possible.

Copyright © 1998-2018 Developer Express Inc.
All trademarks or registered trademarks are property of their respective owners