In order to sort/order the rows of a DataTable, we need to pass them through to an array of DataRow…
Category Archives: ASP.NET
Basics: Page/Control Lifecycle (ASP.NET)
Embarrassing as it may be, I need to keep a note of the lifecycle of pages and controls cause, still,…
Basics: Dictionary (Create, sort + comparison with Hashtable)
Dictionaries are my favourite structure to populate drop down lists. A method that returns a Dictionary will in fact return…
How to: Solve the “empty Ajax Update Panel” predicament; or, why do controls that live in an UpdatePanel always display last.
A funny thing happens if you’re using an empty Ajax Update Panel on your page/control definition in order to programmatically…
How to: Troubleshoot “Failed to enable constraints. One or more rows contain values violating non-null, unique, or foreign-key constraints.”
Working with DataSets, you might face this error message that will keep you from using code that you knew was…
Basics: Panel VS Placeholder (ASP.NET)
One more thing to keep in mind when working with ASP.NET is the difference between the two most commonly used…
How to: Get the currently logged on user’s Username and ID (ASP.NET – v:3.5+)
There’s very easy and practical way to deal with the need to get a user’s Username and ID when programming…
How to: Get random numbers (Random() & RNGCryptoServiceProvider())
For use with simple, everyday projects where you might need a simple random number, Random() should be enough. The only…
Quick tip: Troubleshoot Response.Redirect() in a try/catch clause
If you have a Responce.Redirect(“urlToNavigateTo”) method in your try section of a try/catch clause, you will notice that the debugger…
Basics: DateTime.ToString() format
One of the most useful overloads of the ToString() method is the ability to provide a format for the object…