ASP.NET Dynamic Data and DevExpress Grid

01 February 2009

DevExpress Dynamic Data VideoCheck out this 12 minute ASP.NET Dynamic Data video which shows you how to:

  • Create a basic Dynamic Data website
  • Add LINQ to SQL objects (using Northwind database tables)
  • Replace the Microsoft GridView with ASPxGridView
  • Use the DevExpress LINQ Server Mode DataSource
  • Use Master Pages and Styles

Sound complicated? Don't worry, it's easy and kind of fun. Just follow these 3 steps:

1. Download File

This zip file contains the necessary code files mentioned in the video.

Click here to download: []

2. Watch the video

Watch the DevExpress Dynamic Data Support video.

3. Leave feedback here

What do you think of ASP.NET Dynamic Data? Drop me a line here and let me know.

27 comment(s)
Rory Becker - DevExpress

Very nice....Any chance of VB.Net versions of these files :) ?

2 February, 2009
Rory Becker - DevExpress

Replacement FieldTemplates would also be very cool :)

2 February, 2009
Mehul Harry (DevExpress)

Hey Rory,

Thanks and I'll look into getting a VB version for you.

2 February, 2009
Scott Hunter

Mehul, this is GREAT stuff. Will blog about it next week!

3 February, 2009

Is there a version of the gridview


5 February, 2009
Mehul Harry (DevExpress)

Hi Bryan,

Thanks for the feedback. This release was just the first iteration. We plan to release an updated version which will include editor templates, dynamic validation, ...

I'll blog about it as soon as we it have it ready.

9 February, 2009
Bryan Reynolds_1

Sounds great.

10 February, 2009
web development india

Thats gr8, really nice to know that.

25 February, 2009
Claude Lavoie

Hello Harry,

sounds great explication into your video.

Perhaps, I improving some bugs when I'm trying to rebuild my site after the importation of thoses 2 files (ASPxDynamicGrisView.cs, DynamicLinqServerModeDataSources.cs) into App_Code folder. Since I'm using VB as my language into my VisualStudio.... he really doesnt like your c# files compiling with the designer.vb's file. Do you have any alternative to help me please

Best Regards


6 March, 2009
Scott Hunter

One of the things that we worked on supporting in Dynamic Data is the ability for third party controls

10 March, 2009

First... Great work and great video.

I really want to use this on a current project. However, I'm having trouble getting this to work on my end.

Getting a compile error:

"The name 'DynamicDataManager1' does not exist in the current context"

I see it defined in the .ASPX file but it's like the code behind of the page template is having trouble resolving it.

Steps I've completed:

1. I've successfully built the "vanilla" Northwind Dynamic Data site using a LINQ to SQL data model (working).

2. I've copied the two new class files (ASPxDynamicGridView.cs & DynamicLinqServerModeDataSource.cs) into my "App_Code" directory.

3. I've copied the four custom 'PageTemplate' files into the DynamicData\PageTemplates folder.

4. Added references to the 5 needed DevEx assemblies and set their "Copy Local" attribute to true so they appear in the project BIN folder.

5. I've updated the Global.asax file as outlined in the video

I'm using v8.3 of DevExpress controls. Am I missing something? Anyone else seeing this same issue when following the video directions and beginning from scratch?

- Jeremy

22 April, 2009

OK - After a good night's rest and taking another look @ the problem I've identified the difference that was causing me issues... ASP.NET Project Types.

The sample relies on using an ASP.NET “Web Site” project template while I was taking the more traditional “ASP.NET Web Application” solution/project template approach. I was able to use the ASP.NET “Web Site” approach to follow the instructions in the video exactly and everything worked perfectly on the first try.

Now, for several valid reasons I need to work with “ASP.NET Web Application” projects and not ASP.NET “Website” projects. The thing that was preventing me from moving forward with the sample was that “ASP.NET Web Application” projects require .ASPX pages to have not only a “.ASPX.CS” code-behind file but also a “.ASPX.DESIGNER.CS” file as well… “ASP.NET Website” projects do not have this added .DESIGNER.CS file requirement.

I’ve manually recreated the ‘DevExList’ control in a separate project and have gotten all the issues resolved up to the point of trying to get the ‘ASPxDynamicGridView’ control visible in the design file… which is where I’m getting stuck.

Could someone there @ DevExpress run through this scenario and see if they can get it working for ‘ASP.NET Web Application’ project types?

23 April, 2009

Hmmm... OK different issue. Does the 'ASPxDynamicGridView' control understand 'System.ComponentModel.DataAnnotations' markup? If not this is a dead-end for me.

i.e. - If I want to turn a column off using extended Metadata attributes? [ScaffoldColumn(false)] or define an alternate display name [DisplayName("Some Column Name Override")]

- Jeremy

23 April, 2009
Mehul Harry (DevExpress)


We haven't tested Dynamic Data web apps much, mostly just the web sites. Web apps probably require different template pages. In general though, the markup should remain the same.

To make the ScaffoldColumn attribute work, replace the ASPxDynamicGridView.AddDataColumns method with this one

void AddDataColumns(MetaTable meta) {

   foreach(MetaColumn column in meta.Columns) {






(column.Scaffold check added)

The DisplayName attribute functions properly.


25 June, 2009
Tristen Lopez

Have you had any progress on releasing a VB version?


21 August, 2009
The ASPx Blog - Mehul Harry's DevExpress Blog

I have good news for Visual Basic developers interested in the DevExpress Dynamic Data Grid called the

14 September, 2009
Graham Charles

I'm getting the same error --

"The name 'DynamicDataManager1' does not exist in the current context"

As Jeremy, using v9.3 of the controls. Any advice?



29 April, 2010
Mehul Harry (DevExpress)


Did you see my reply to @jeremy as well @jeremy's own response about the project type?

29 April, 2010

Can you update and post the files for ASP.NET 4.0 and also DevExpress 10.1.3?

7 May, 2010
Mehul Harry (DevExpress)


Not sure about 10.1.3 yet but we'll consider it for a future release. Thanks.

8 May, 2010

Can you maybe just update the files for V10.1.3 and post them to the blog.  I am evaluating this control for a project that I am developing & really need this capability but, was hoping that I would have this ability if I bought the DevExpress controls.  Can you please make an effort to update the files and post them?



12 May, 2010
Luis Valencia Muñoz

We are doing a dynamic data with aspxgridview proof of concept I have the following errors:

I tried to add references to, but it says they are on the project.  I checked the bin folders but neither dlls are there.

using DevExpress.Data.Linq;

using System.Data.Linq;

using System.Linq;

Error      1              The type or namespace name 'LinqServerModeDataSource' could not be found (are you missing a using directive or an assembly reference?)                D:\EPM.ControlPerdidasGAS\EPM.ControlPerdidasGASLineaBase\SlnEPM.ControlPerdidasGAS\EPM.Gas.CorePerdidas.SitioPerdidas\App_Code\DynamicLinqServerModeDataSource.cs                9              52           localhost/EPM.Gas.CorePerdidas.SitioPerdidas

Error      2              The name 'ContextTypeName' does not exist in the current context                D:\EPM.ControlPerdidasGAS\EPM.ControlPerdidasGASLineaBase\SlnEPM.ControlPerdidasGAS\EPM.Gas.CorePerdidas.SitioPerdidas\App_Code\DynamicLinqServerModeDataSource.cs                17           41           localhost/EPM.Gas.CorePerdidas.SitioPerdidas

Error      5              The name 'TableName' does not exist in the current context                D:\EPM.ControlPerdidasGAS\EPM.ControlPerdidasGASLineaBase\SlnEPM.ControlPerdidasGAS\EPM.Gas.CorePerdidas.SitioPerdidas\App_Code\DynamicLinqServerModeDataSource.cs                24           26           localhost/EPM.Gas.CorePerdidas.SitioPerdidas

31 August, 2010
Mehul Harry (DevExpress)


The LinqServerModeDataSource is part of the DevExpress.Data.Linq assembly which you'll need to reference in your project:

31 August, 2010
Luis Valencia Muñoz

I already referenced it, but still doesnt compile I am using latest version of the controls.

Other strange thing is that the dlls dont appear on the bin, I guess its because they are in the GAC so they get referenced in the web.config

31 August, 2010
Luis Valencia Muñoz


<add assembly="DevExpress.Data.v10.1, Version=, Culture=neutral, PublicKeyToken=B88D1754D700E49A"/>

<add assembly="DevExpress.Data.v10.1.Linq, Version=, Culture=neutral, PublicKeyToken=B88D1754D700E49A"/>

<add assembly="DevExpress.Web.v10.1, Version=, Culture=neutral, PublicKeyToken=B88D1754D700E49A"/>

<add assembly="DevExpress.Web.ASPxGridView.v10.1, Version=, Culture=neutral, PublicKeyToken=B88D1754D700E49A"/>

31 August, 2010
Bryant Farley

Having problems as well with using the VB sample and latest version ( of controls. No compilation errors when building site, but errors when trying to run the page.

14 November, 2010
Mehul Harry (DevExpress)

Hi Bryant,

We're looking into the latest Dynamic Data support and I'll have some more news for you soon. Keep an eye on this blog in the meantime:


20 December, 2010

Please login or register to post comments.