Thursday, July 18, 2013

System.ArgumentException: The version of SQL Server in use does not support datatype 'datetime2'.

It turns out that Entity Framework 4 somehow got the idea to use SQL Server 2008. The fix was to edit the .edmx file in an XML editor and set the ProviderManifestToken="2005" instead of 2008. (You need to rebuild.)

Wednesday, July 10, 2013

asp.net checkbox modalpopupextender checkbox doesn't check or uncheck

Answer Link:  http://forums.asp.net/p/1072619/1568169.aspx
http://wyerarch.blogspot.in/2010/04/aspnet-checkbox-modalpopupextender.html

Wednesday, May 22, 2013

For the EntityDataSource, if the query specifies a projection and paging is enabled, a sort expression must be defined. Either set the OrderBy property or set AutoGenerateOrderByClause to true.

Use Order BY Clause

1:   <asp:EntityDataSource ID="EntityDataSource1" runat="server" ConnectionString="name=Entities"  
2:      DefaultContainerName="Entities" EnableFlattening="False" EntitySetName="tblContacts"  
3:      EntityTypeFilter="tblContact" Select="it.[ContactCode], it.[FirstName], it.[LastName], it.[AddedAt] "  
4:      OrderBy="it.[AddedAt]">  
5:    </asp:EntityDataSource>