I am trying to do somthing like this:
// some code...
string a="aa";
string b="bb";
// ...
if(b>a) // suppose to be true
{
// do somthing
}
But then I get the compile error:
Operator ‘>’ cannot be applied to operands of type ‘string’ and
‘string’.
So what is the best approach?
Use
CompareTo()method instead of.This method ;
Check this
DEMO.