C# : How to Create a DateTime object from a string date
In C#, Creating a DateTime object from a Date String is as follows.
string strStartDate=”11/11/2009″;
DateTime objStartDate = DateTime.Parse(strStartDate);
The objStartDate object,which is an object of DateTime class, is now holding the date and u can use this object for all date manipulation functions
Always use DateTime wherever handling the dates instead of using String.DateTime gives u flexibility to work more on that like performing date manipulation
