the code as follows;
DateTime dateofbirth = Convert.ToDateTime(txt_DOB.Text.ToString());
DateTime Weddingday = Convert.ToDateTime(txt_wedding.Text.ToString());
if(dateofbirth.Year.ToString()!="1900")
SendSMS(txt_DOB.Text.Trim());
else if(Weddingday.Year.ToString()!="1900")
SendSMS(txt_wedding.Text.Trim());
when i run this code error as follows;
string was not recognized a valid date time.
from my above wat is the problem help me.
Loading
Satyapriya NayakPosted Dec 29, 2012, 8:26 AM
Duplicate thread
http://www.c-sharpcorner.com/Forums/Thread/197588/error1operator-cannot-be-applied-to-operands-of-type.aspx