You have to convert both date in perticular format like "MM/dd/yyyy"
or "dd/MM/yyyy" then apply your logic to compare date which are in same format
means you should do folowing steps
1 convert both date in same date format you can convert this using
ToString("your date format")
2 if you want use DateTime.Compare() then convert both date in DateTime.
string doj = Convert.ToString(cboFromMonth.SelectedItem.Value) + Convert.ToString(cboFromdate.SelectedItem.Text)
+ Convert.ToString(cboFromYear.SelectedItem.Text);
DateTime cmb_date=Convert.ToDateTime(doj)
DataTable dtTemp = new DataTable();
dtTemp = (DataTable)Session["PreEmploymentDetail"];
if (dtTemp != null)
{
for (int i = 0; i <= dtTemp.Rows.Count - 1; i++)
{
int result = DateTime.Compare(Convert.ToDateTime(doj), Convert.ToDateTime(dtTemp.Rows[i] ["ToDate"]));
if(result < 0)
{
}