> I have a collection of items (object) that I need to
retrieve there
> corresponding string value at present I'm calling
ToString() but should
> I be calling the corresponding type converter?
That depends upon what you mean by 'corresponding' string
value.
Are your objects "strings" - as in logical
inheritance? Do your objects
have a serialised string representation? Are you trying to
get a
user-displayable description of the object to display on the
UI?
In the absence of detailed knowledge of your architecture,
I'd suggest
that maybe your base class should have a
"MyStringValue" abstract
method that returns the string you want - no ambiguity,
then.
John
===================================
This list is hosted by DevelopMentorŪ http://www.develop.com
View archives and manage your subscription(s) at http://discuss.develop.com
|