Administrator

Administrator

  • Tech Writer
  • 2.2k
  • 1.5m

How to copy an object?

Apr 10 2003 9:57 PM
I want to copy the contents of a hashtable to another hashtable. I tried the following ways: //ht1, ht2 are two hashtables 1. ht1=ht2; 2. ht1=new Hashtable(); ht1=ht2; In both ways, the reference is copied, instead of the data. Are there any way that I can copy it? Thanks a lot

Answers (3)