How To Make a Column in an ASPxGridView ReadOnly for Editing but Enabled when Inserting a New Record

The Situation: You have a DevExpress ASPxGridView on your page with a column designated as "ReadOnly=true". This works great when you are editing an existing record -- it won't allow you to change that field, but when you try to insert a NEW record, you can't enter anything in the field. Note: I don't know … Continue reading How To Make a Column in an ASPxGridView ReadOnly for Editing but Enabled when Inserting a New Record

Entity Framework: Repository or Not Repository?

On the heels of the demise of the commercial version of EntitySpaces, I am delving into Microsoft's Entity Framework. I need to implement it in a big project to replace a much more manual Data Access Layer. So I've done a ton of reading on it (and played with it some, too), and the common … Continue reading Entity Framework: Repository or Not Repository?

How to Pass Extra Parameters When Using AJAX Toolkit CascadingDropDowns with a Database

The Situation: You have set up your CascadingDropDowns as shown on the ASP.NET AJAX Control Toolkit documentation here, using a web service to retrieve and populate your dropdowns. However, in addition to the value of the first dropdown, you need to pass other parameters to the web service to be used in your query. A … Continue reading How to Pass Extra Parameters When Using AJAX Toolkit CascadingDropDowns with a Database

How to Force an ASP.NET Page into IE Compatibility Mode (Even when Using Themes)

The Situation: You need to to use a control that is not fully compatible with the latest version of Internet Explorer (or you find that your page just doesn't function the same in the latest version). A Solution: The normal solution (and the one that nearly everyone can use UNLESS they are working with ASP.NET … Continue reading How to Force an ASP.NET Page into IE Compatibility Mode (Even when Using Themes)

How To Edit a Record in an ASPxGridView Bound to EntitySpaces’ esDataSource that Uses a Join

The Situation: You get an error when you try to save edits to a record in a DevExpress ASPxGridView. The grid view is bound to an EntitySpaces esDataSource, which is populated using EntitySpaces dynamic query functionality. The ES dynamic query syntax allows you to use joins between entities like this (actual code from one of … Continue reading How To Edit a Record in an ASPxGridView Bound to EntitySpaces’ esDataSource that Uses a Join

How to get the value from a GridView column on RowDeleting

The Situation: You need to get the value of one of the columns in the row you are deleting in a GridView to do some processing before the row is deleted. A Solution: When using the RowDeleting method, you cannot use e.Row.Cells[1].Controls[1] to get the control in that cell like you can in the RowCreated … Continue reading How to get the value from a GridView column on RowDeleting