Category Archives: GridView

Conditional Formatting in a GridView

This code will allow you to change the background colour of a cell or entire row depending on certain conditions. In this example we test if the row being bound is a data row, then if the second column (indexed … Continue reading

Posted in ASP.NET, Cells, GridView, Row | Tagged , , , , , , | 6 Comments

Confirming delete actions in ASP.NET

When working with databases and the SQL DeleteCommand it may be a good idea to double check that this is what the user intended to do before risking permanently losing data. Continue reading

Posted in ASP.NET, ButtonField, DeleteCommand, GridView, OnClientClick, TemplateField | Tagged , , , , , , , , , | 1 Comment