When using radio button in a repeater item template, there's a problem of grouping them to a unique name. Solution can be found: http://www.developer.com/net/asp/article.php/3623096
A very useful statement to check if a constraint exists before do something to it. Note, we can never edit a constraint before deleting it and re-create. SELECT * FROM INFORMATION_SCHEMA.TABLE_CONSTRAINTS WHERE CONSTRAINT_SCHEMA='dbo' AND CONSTRAINT_NAME='FK_37_Page_FK' AND TABLE_NAME='PageContent'
Ever wanted to create a gradient image dynamically? This can easily be done using C# with the following snipplet of code. We can also specify the width, height, gradient direction (horizontal or vertical), and the two colors. By using LinearGradientMode class, a beautiful gradient image can be drawn in a sec.