"Tu-Thach" <tu*****@yahoo.com> wrote in message news:<07****************************@phx.gbl>...
There is no simple way to do this other than writing the
code yourself. Typically, you would implement
ICloneable.Clone() to clone your Client object.
The only possible problem with this approach is the added cost of maintaining
the Clone method if you had to modify the class, which isn't much of a problem
once you have the method implemented.
Another possible approach--one that I have used previously--is to mark the
class in question as serializable, and inside the Clone method seralize the
source object into a MemoryStream object, then deserialize it into the copied
object. Works like a charm, if you don't mind the possible performance
overhead, which shouldn't be significant.
-LM