Use of “as” keyword as for casting in C#

2009-01-06 The keyword as doesn’t throw an exception if it fails to complete the casting operation. Instead it will return null. Other casting operations will throw an exception when the provided value cannot be casted. Since the “as” keyword sets or returns “null” value when it fails, the variable you use must be of aContinue reading “Use of “as” keyword as for casting in C#”

How to use LIKE operator in Dataview.RowFilter for Date Time or Numaric Fields using CONVERT

2012-01-16 // http://pagead2.googlesyndication.com/pagead/show_ads.js The RowFilter property of the DataView allows to use flexible string similar to SQL or LINQ to easily filter rows wihtout having to iterate through them. I had to implement a fully flexible search module for a project I’m working on. The user had to be able to perform a string searchContinue reading “How to use LIKE operator in Dataview.RowFilter for Date Time or Numaric Fields using CONVERT”

C# ASP.NET – GridView : How to Use Checkbox in Gridview to Select Multiple Rows

2009-01-06 // http://pagead2.googlesyndication.com/pagead/show_ads.js I wanted to select multiple rows of the grid view using check boxes to select each row. In this post I will discus how and what I did to achieve this goal… I used a template column which holds a check box to select or de-select a row in the grid view.Continue reading “C# ASP.NET – GridView : How to Use Checkbox in Gridview to Select Multiple Rows”

C# ASP.NET – GridView : How to Keep Modified Data of Template Fields when Paging is Enabled?

2008-12-04 Today I had to take care of a problem of a certain company (CIS) that I consult. They had a problem of keeping the values modified in a template field of a gridview when the user moves from one page of the grid to another. Template fields allow us to add custom columns intoContinue reading “C# ASP.NET – GridView : How to Keep Modified Data of Template Fields when Paging is Enabled?”