What is difference between Convert.ToString(variable) and
variable.ToString()
Answer Posted / pavel
object ss =null;
string s1 = ss.ToString(); ---------- exeption
string s2 = Convert.ToString(ss); --- ""
--------------------
int ss =null; --- int can't be converted to null
--------------------
int ss = 1;
string s1 = ss.ToString(); ---------- "1"
string s2 = Convert.ToString(ss); --- "1"
| Is This Answer Correct ? | 0 Yes | 2 No |
Post New Answer View All Answers
Define using statement in c#?
Why is xml called extensible?
What is the difference between a class and an object c#?
How do you mark a method obsolete?
What is difference between dictionary and hashtable?
What is the difference between parse and tryparse in c#?
What is the major difference between a custom control and user control?
Define satellite Assembly in .NET?
Are c# destructors the same as c++ destructors?
What is the difference between package and interface?
What does static mean in c sharp?
What is a cs file?
Can abstract class have constructor?
What are the fundamental principles of oo programming?
What are reflections in c#?