.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Dynamic Data, Domain datasource, Poco and lookups

Posted By:      Posted Date: August 21, 2010    Points: 0   Category :ASP.Net

Mr. Edward,

Excuse my question but: it is necessary to involve in our projects something more than just Dynamic Data or should we make use of all other features available in VS2010 (which will make assume taht they had been left out of the Dynamic Data framework) like: wef, poco, azure, wcf, cloud, mvc, silverllight, ajax, odata, agile, workflow, etc.?

Sorry my ignorance, I'm just transcribing names as they come to my mind and of which I don't know anything about


Carlos Porras (El Salvador)

View Complete Post

More Related Resource Links

Customizing pages with Asp.Net Dynamic Data Domain Service Web Applications?

Hola, It used to be so easy creating new folder under CustomPages with the (Entity/Table name) and copying on it all base default PageTemplates (Details, Insert, Edit, List and ListDetails) and you will get access to those pages only for the specific table (this was the default automatic behavior of the Dynamic Data framework) When it comes to be using Asp.Net Dynamic Data Domain Service Web Applications it seems that we need to learn a new way of doing this because it is just simply different and you got a lot of errors when compiling your application if you do this the old way? What might be the new way, uh? HOW DO WE DO THIS NOW ... I MEAN ... CREATING DEFAULT CUSTOM PAGES FOR SPECIFIC TABLES (Details, Insert, Edit, List and ListDetails) with Asp.Net Dynamic Data Domain Service Web Applications? The problem arises when the definition for your newly created classes is absent from the automatically generated code when you created your domain service !!!!! . If you simply copy the PageTemplates as they are, you got a duplicated error message because the new .designer file (automatically generated) conains the definition of the class you are copying (not the newer one) so even if you rename your .aspx file the result is not what you would normally expect (the .designer class is not regenerated after renaming). The .designer file keeps the domain service definition and if y

Cannot INSERT record using Asp.Net Dynamic Data Domain Service Web Applications

 Hi, I am working on a 'Asp.Net Dynamic Data Domain Service Web Application' project using just 2 tables, FAQ_Categories and FAQs. The FAQs table has a foreign key to the FAQ_Categories. The steps are straight forward. Add a new project (Asp.Net Dynamic Data Domain Service Web Applications) Add folders Model ( for Linq2Sql datacontext), Domain (for the Domain Services class) Add Linq2Slql and add the 2 tables to the designer. Build the project. Add the Domain Service Class to the Domain folder. in the wizard select the DataContext, uncheck the Enable Client & Expose ODate checkbox Check bothe table & their corresponding Enable Editing tables checbox Check the Generate Metadata class Click OK. In Global.asax set Scaffold to true and add the DomainService name. Build and run.   Pages List and Detail are working fine. But if I try to insert a new record, I get the error "FaqId is required" Faq_ID is the primary key in the database table and it is set to Identiy. The Datacontext is correct, it marked the FAQ table with <Global.System.Data.Linq.Mapping.ColumnAttribute(Storage:="_CustomerId", AutoSync:=AutoSync.OnInsert, DbType:="Int NOT NULL IDENTITY", IsPrimaryKey:=true, IsDbGenerated:=true)> _   I tried this using Linq2Sql, Entity Framework, And both in VB and C# with the same result. I am using VS20

Dynamic Data, Domain Services & POCOs...


I have a simple navigation property between two pocos (parent/child) and I'm using the [Key], [Include], [Association] attributes to notate the relationships. However, when DomainModelProvider attempts to load my model -- I get this error:

[InvalidOperationException: Can't find To column for column 'myColumnName'] Microsoft.Web.DynamicData.ModelProviders.DomainColumnProvider.Initialize() +649

Rather than parade my horribly broken code around -- I was wondering if anyone has a good resource or guides on how to use DomainService/Dynamic Data together using custom POCO models with 1:1/1:M relationships -- rather than EF/L2SQL driven data models. I figure I'd start there before giving up.


Get primary key values from insert page and route to details page in a Dynamic Data Domain Service A


I finally figured out how to retrieve primary key values from the insert page template that are inserted via defaults in a SQL Server database. I wanted to get the keys so that I could route the user from the insert page template to the details page template (regardless of whether it’s a custom route or not). There are a number of scenarios where separate insert and details pages are desirable, and routing from the insert page back to the list page is not desirable as Dynamic Data does out of the box. Since I could not find an answer to this problem anywhere with significant effort, I decided I would document it for others, I hope you find it useful - it turns out that it's quite simple under 10 lines of code. I also applied the same idea to a Dynamic Data Entities application which works exactly the same except for two minor changes, I have documented it below as well.

For starters, as is documented plenty elsewhere but bears repeating here, you must first annotate your Entity Data Model with ScaffoldColumn = false for identity columns and guids that get assigned with newid() in thedatabase. This tells Dynamic Data not to attempt to pass a null value from the page through to

Dynamic Data Templates in GridView ASP.NET 3.5

At a high level, Dynamic Data Templates can be seen as a system to very quickly build up a User Interface linked with the relevant data model, immediately enabling you to perform CRUD operations (Create, Read, Update, Delete) on the database using the specified data source. They provide a powerful method for building up these kinds of applications, and I'm going to focus on an overview of what Dynamic Data Templates actually are, and a few ways of customizing them to suit industry needs.

ASP.NET 4.0 Dynamic Data and Many to Many Entity Framework Entities

I did not play much with Dynamic Data controls in VS2008 and just made a cool discovery in VS2010 Beta 2. This may not even be new, but as I'm sitting 30,000+ feet over the Atlantic ocean, I don't have access to VS2008 at the moment to check.



Dear gentlemen and ladies of the Microsoft Dynamic Data Team,

Mr. Steve Naughton says (and I hope so) that there might be chances that you read the posts published in this forum: I really hope so.

If that were the case then I am formally requesting to you in providing a "real answer" to my question:

I want to customize a dynamic data page (the details one) so I can have access to the data it has been already gathered from the end user UI (details.aspx) and use it to pass this same data to the following controls/pages that I am going to display next time to the end user.

For instance:

I have a screen with different types of data in it: texts, numbers, dates, check boxes, radio buttons and dropdownlists that has been filled with data by the end user. I want now to reset all fields exept the dropdownlist of which I'd like to keep the previously chosen values(the very same thing you do between dropdownlist of List.aspx ad Details.aspx). Even with FoxPro I could do that because data and controls were available there. It was as simple as setting carrying on to true.


I have found my

Routing in dynamic data applications


Im using ASP.Net 4. I tried to modified the code according to following video tutorial. http://www.asp.net/aspnet-in-net-35-sp1/videos/how-to-enable-table-specific-routing-in-dynamic-data-applications

But Product page directs only to ListDetails.aspx page.

This is my code :

<%@ Application Language="C#" %>
<%@ Import Namespace="System.ComponentModel.DataAnnotations" %>
<%@ Import Namespace="System.Web.Routing" %>
<%@ Import Namespace="System.Web.DynamicData" %>

<script RunAt="server">
    private static MetaModel s_defaultModel = new MetaModel();
    public static MetaModel DefaultModel {
        get {
            return s_defaultModel;

    public static void RegisterRoutes(RouteCollection routes) {

        DefaultModel.RegisterContext(typeof(NorthwindDataContext), new ContextConfiguration() { ScaffoldAllTables = true });


About Dynamic Data in Visual Studio 2010 / .NET 4



Does anybody here have any pointers to screencasts, demos, webcasts for the latest enhancements in Dynamic Data as listed in above link? I'm repeating them here for ready reference :


  • EnableDynamicData method which enables Dynamic Data features in existing ASP.NET applications and DataSource controls
  • A new QueryExtender control, contained in the sample projects to simplify common data filtering operations. It supports a rich ASP.NET declarative query syntax that makes it easy to do things like search data for text or have filters based on ranges
  • A new Dynamic Data filter model that enables the developers to apply templates to pages just like field templates (including user defined filters)
  • New field templates of Email, URL and Enum columns
  • Support for inheritance in Entity Framework and Linq to SQL
  • Support for many to many relationships in Entity Framework
  • New Entity Templates which allow fine control over how an object is displayed and edited
  • DynamicHyperLink control for building links to tables and actions
  • Declarative support for D

How to sell Dynamic Data to the bosses


I have a project which has gone from Excel report to a SharePoint Custom List and now they have tried to make it an application growing legs with additional list hinging off it and no real way to clean up data from one when it deleted from another etc..(unless we add handlers etc which we don't want to do).

It was envisiaged as a simple one page list to generate some reports off of but it more a data driven application they want now.

I am looking into a way after stating this to my boss and am intrested in the quickest most flexible way to achieve this and to sell it to him.

I am more a .net person but also know plsql and most of the team I work with are Oracle specialists.

We currently have at are disposile .net, php and oracle products (portal, plsql, forms and oracle application express.)

We are at a transition stage trying to move away from Oracle Forms and I believe that .net is a better fit that php for production and readability of code.

So I am considering placing Dynamic data on the table for this project as it all data driven with data being inputed and manipulated and then reports being generated (either via code or we could hitch in a reporting tool like mssql or discover.)  The main issue will be the data will be in Oracle so if Dynamic data can handle this then it be perfect as

Dynamic WPF: Create Flexible UIs With Flow Documents And Data Binding


Flow documents offer enormous flexibility in arranging text layout and pagination, but they don't support data binding, so you can't dynamically change content. Here we build a component to solve that problem.

Vincent Van Den Berghe

MSDN Magazine April 2009

Basic Instincts: Dynamic Data Entry With XML Literals


Learn how to use Windows Presentation Foundation (WPF), XAML, and the deep XML support in Visual Basic to generate user interfaces dynamically.

Beth Massi

MSDN Magazine October 2008

SQL Server 2005: Fuzzy Lookups and Groupings Provide Powerful Data Cleansing Capabilities


SQL Server 2005 offers a completely redesigned SQL Server Integration Services engine, formerly known as Data Transformation Services. It includes many new features such as built-in support for Fuzzy Lookups and Fuzzy Groupings, which help you build powerful data-cleansing solutions. This article provides an overview of fuzzy searching techniques and a dissection of the underlying fuzzy search technology implemented in SQL Server 2005.

Jay Nathan

MSDN Magazine September 2005

Dynamic Data Use And Limitations


I have been looking at dynamic data based applications for a little while now and it looks like this technology could be deployed in many scenarios. In my case I am interested in using it to deliver relatively small database applications to small to medium sized companies, often replacing data in homespun spreadsheets with a well ordered database. The attraction to me being that dynamic data allows the application to be created (and subsequently altered) much more efficiently than with lots of hand coded web forms.

What experience have others had using this technology on live sites, have you come across any road blocks or gotchas in terms of performance, security or general functionality? Is it being used in a diverse range of scenarios?

Dynamic Data Entities Modal GridViewPager not showing


I am using the ModalEF template, converted to a web application.

The GridViewPager is not showing up, though everything else works fine (filters, updates, etc).

I have tried several things in the last two weeks, to no avail.

Any assistance would be greatly appreciated.

The GridViewPager.ascx.cs Page_Load fires, but the Page_PreRender does not.




<%@ Page Title="" Language="C#" MasterPageFile="~/DefaultMaster.master" AutoEventWireup="True" CodeBehind="ListDetailsModal.aspx.cs" Inherits="DATTWeb.DynamicData.PageTemplates.ListDetailsModal" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajaxToolKit" %>
<%@ Register Assembly="System.Web.Entity, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089" Namespace="System.Web.UI.WebControls" tagprefix="asp" %>

<%@ Register src="~/DynamicData/Content/GridViewPager.ascx" tagname="GridViewPager" tagprefix="asp" %>
<%@ Register src="~/DynamicData/Content/FilterUserControl.ascx" tagname="DynamicFilter" tagprefix="asp" %>

<asp:Content ID="Content2&quo

What is a good example Dynamic Data application?


I'm giving a demonstration of Dynamic Data to a bunch of geeks in two weeks time. I'm looking for a simpe, but comprehensive data model to build the application on. I basically just want to register the model and demonstrate the application, as built (scaffolded) without any customisation, to start with, demonstrating list and detail/edit/insert views, and how table relations are handled.

I'd like to avoid one of the standards, i.e. the Customer->Order-OrderItem models, and try something that would be of interest to geeks. Maybe a Srum project tracker, an or a bug tracker, something like that.

Any suggestions please?

This was originally asked by myself on StackOverflow at: http://stackoverflow.com/questions/3536803/what-is-a-good-example-dynamic-data-application

Which ComponentModel.DataAnnotations attributes are used in the Dynamic Data metadata classes?


This namespace contains a lot of attributes for use in, I'm sure, many different applications. I'm curious to know which subset of the attributes in this namespace can be and are used in the Dynamic Data proxy class system, where the entity class is given an attribute that specifies a metadata type. That type contains properties with the same names as properties in the entity class, and the metadata provider builds MetaColumns using attributes on properties in these 'buddy' (proxy') classes.

So far my list includes, from System.ComponentModel.DataAnnotations:

Required, Range, DisplayFormat, StringLength, UIHint, DataType, Regular Expression, Display Column, Editable, and CustomValidation.

And from System.ComponentModel:

DisplayName, Description, and DefaultValue.

Am I missing any?

This was originally asked by myself on StackOverflow at: http://stackoverflow.com/questions/3537356/which-componentmodel-dataannotations-attributes-are-used-in-the-dynamic-data-meta

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend