When i do compare 2 string current date and past date it shows me that current date is not bigger than past date.
I tried to compare str and str2 and the comparison is true.
string str="21/05/2019";
string str2="7/06/2019";
string c=GetCurrentDate();
if(c>str)
{
cout<<"true";
}
and function
inline string GetCurrentDate()
{
auto t = time(nullptr);
auto tm = *localtime(&t);
ostringstream oss;
oss << put_time(&tm, "%d/%m/%Y");
auto strCurrentDate= oss.str();
return strCurrentDate;
}