Wednesday, August 14, 2013

LINQ- Difference between First and FirstOrDefault- First vs FirstOrDefault

In my previous post Single vs SingleOrDefault, we talk about Single and SingleOrDefault method and difference between these methods. In this post we are going to explore two more extension methods First and FirstOrDefault.


You can find some other useful topics and posts here. Below is a chart explaining about First() and FirstOrDefault(). You can easily differentiate these methods from this chart. I have also given examples of each method.

Monday, August 12, 2013

LINQ- Difference between Single and SingleOrDefault- Single vs SingleOrDefault

In today's development, we all are frequently users of LINQ. So In this post and some incoming posts, I will try to explain about some LINQ's extension methods that seems trivial, but can really helpful to improve your code by making it easier.

Here, In this post I am going to explain you about Single and SingleOrDefault method and difference between these methods.

You can find some other useful topics and posts here. Below is a chart explaining about Single() and SingleOrDefault(). You can easily differentiate these methods from this chart. I have also given examples of each method.

Tuesday, August 6, 2013

SQL Server- User Defined Function to Parse HTML- Strip HTML -Without Using Regular Expression

This is a simple tip post. In this post I will show you a user defined function in SQL Server which parse the HTML and retrieve the Text only from it.

In previous posts, I explained Case Sensitive Search in SQL Server, Check Primary Key Existence in Table, Reset Identity Column in SQL Server, Insert Values into Identity column, Identity Column in SQL Server , STUFF Function, LEN Function, UNICODE Function, LEFT Function, CHARINDEX Function, Simple script to backup all SQL Server databases, Table-Valued Parameters and some other articles related to SQL ServerASP.Net, C#.

Following UDF takes the HTML as input and returns Text only from it. Please note you need to replace all the single quotes (if any) with two single quote (not double quote) in HTML before passing it as input to function.

Tuesday, July 23, 2013

How To- Send DataGridView Data in Email in Window Form Application

In my one post I explained you how to Send Grdiview Data in Email. Here I am going to show you how to send DataGridview content in E-mail in window application.

You can also find my other articles related to C#ASP.Net jQuery, Java Script and SQL Server.

First take a look on the below image.
DataGridView with Data

^ Scroll to Top