R
Raj
string str1="rakshith";
if(str1.ToUpper()=="RAKSHITH")
{
//DO SOMETHING
}
Console.WriteLine("str1 value is : " + str1);
//prints as "RAKSHITH
if(UCase(str1)=="RAKSHITH")
{
//DO SOMETHING
}
Console.WriteLine("str1 value is: " + str1);
//prints as rakshith
Seems ToUpper() makes str1 mutable whereas in C# it is not!!
Any help would be appreciated
Thank you
Regards
Raj
if(str1.ToUpper()=="RAKSHITH")
{
//DO SOMETHING
}
Console.WriteLine("str1 value is : " + str1);
//prints as "RAKSHITH
if(UCase(str1)=="RAKSHITH")
{
//DO SOMETHING
}
Console.WriteLine("str1 value is: " + str1);
//prints as rakshith
Seems ToUpper() makes str1 mutable whereas in C# it is not!!
Any help would be appreciated
Thank you
Regards
Raj