المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : int.Parse() and Converter.toInt()



C# Programming
06-09-2009, 01:51 PM
we know that there are at least two ways to convert a string to a number, let's say, int:

int.Parse('100')

convert.toInt32('100')

I also read from one book that Convert is at cost of some performance. why? does it mean that it is better to use .Parse() instead of using Convert?

thanks!