SelectStartDate.click();
DateFormat dateFormat = new SimpleDateFormat("dd MMMMM yyyy");
Date date = new Date();
System.out.println(dateFormat.format(date));
for(int i=0; i==DateList.size(); i++)
{
// if(DateList.get(i).isSelected())
//{
//System.out.println(DateList.get(i).isSelected());
//String date = DateList.get(i).getText();
//if(date==dateWithoutTime)
if(DateList.get(i).getText().equals(date))
{
OKButton.click();
}
break;
}
}
}
HERE IF STATEMENT IS not getting executed. could you please tell me why?