Making Long Forms Easier [.NET]

If you have an unwieldy form, like I do, it can be a pain when you click an action button near the bottom of the page and have it scroll all the way up on PostBack. Here's a simple way to fix that. More »

Power Tip: Convert a string to an array of Integers

Here are two extension methods that can convert a string (delimited by anything of your choosing) into an array of integers. Successfully handles any non-Integer data smoothly as well. More »

Using GUIDs in LinqDataSource Controls

Having trouble using Guid IDs in your LinqDataSource controls? This was a small tip I learned searching across the web. I will show you how you can do it, it's possible! More »

Maintaining Checked State On Radio/Checkbox Controls On Post Back

I had a unique problem today. Here's the scenario: You have a ListView that dynamically loads different ItemTemplates depending on a specific criteria (in my case, a category). You load this user control template into the ItemTemplate and create some radio and checkbox buttons. If you set GroupName on the controls to a group name, .NET will not associate all the different buttons across the templates because they have different naming containers. More »

How To: Use a ListView to Make People Read a Statement Before Filling Out Your Form

I use a ListView to display a form based off of a data model that people fill out. I know that ListViews are meant for lists but I like that you can databind it to a source so you don't have to do any code behind. In my case, I just need values from a custom control within the ListView. More »

Yes, You Can Manage Solutions Using Different Source Control Providers

I had that question today as I just branched a piece of my current project into its own side project on CodePlex. I wondered since I was using TFS as the default source control plug-in in VS.NET whether I couldn't open my SVN-controlled solution. It turns out, you can! Apparently it is solution-scope and not application-scope, so in one VS instance you could have a TFS project open, in the other, your SVN project. That is my current state right now.

If you're wondering, the project is jForms.NET, hosted on CodePlex. I am moving my current code into the new C# project, improving it to support better flexibility for other people's needs. I need to finish it so I can subclass it for my current project to support custom Linq to SQL validation (i.e. no validation controls on forms!), which I will also release later too.

Easily Select Controls Using Complex Expressions [Sizzle]

If you've used jQuery before, you know you want that kind of amazing selector functionality for .NET. The good news is that you can get that kind of complex selecting using a free code snippet called Ra.Selector. It supports finding controls by type according to a predicate (boolean expression) and also recursively finding a control by ID. More »

LINQ-to-SQL Bug: Using Property Name vs. DB Column Name for GUIDs

I came across this error today when working with my LINQ-to-SQL insert logic. "Invalid column name 'Id'." At first, I didn't understand why it was throwing this error because the source name was correct, "MyColumnRowGuid."

I had Auto-Sync set to OnInsert and Auto Generated set to True. I found out that it wasn't my fault, it's an actual bug with LINQ-to-SQL. It won't be fixed until .NET 4.0, so I am left to my own devices.

How did I get around this without changing the column name? I just had Linq use a sproc for the Insert method, generated the ID on the SQL side and returned it as a parameter.

An error has occured while trying to process your request. Hide