Hi Marlon,
From a general view, I always think call obj(or other class's ) ToString
will be better if there is no particular requirement ot use any Convert
class to do the same task. And as for the CStr, this is a visualbasic
compatible expression which is actually translated to the following call at
runtime:
Microsoft.VisualBasic.CompilerServices.StringType.FromObject(Object value)
in microsoft.visualbasic.dll
And the StringType.FromObject will also do a switch list to compare the
object's Typecode and do the convertion. So I think directly use ToString()
method is always the preferred way.
Do you think so?
thanks.
Regards,
Steven Cheng
Microsoft Online Support
Get Secure!
www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)