Can anyone please explain me what is the difference between these two string Type Casting method.
Type 1
int i = 90;
string b = i.ToString();
Type 2
int i = 90;
string b = Convert.ToString(i);
I want to know the major difference of using the two different approach. The 1st one is to handle the null value,we can use 'Convert.ToString();
'. And moreover I get to know that '.ToString()
' can be override.
Can anyone can explain how. And which one is good to use.
Thanks in Advance.