O
OpticTygre
If I pass an object to another form via the new form's tag property, I want
to create an object exactly like it, with it's properties and all, but have
it be a copy of the object passed through, and not just a reference to the
object.
Example:
Public Sub Form_Load(ByVal sender as Object, ByVal e as EventArgs)
Dim obj as Object = Activator.CreateInstance(Me.Tag.GetType())
obj = Me.Tag
When I say that obj = Me.Tag, then it only provides a reference to the
object in the Tag property. How can I create an exact duplicate instead?
TIA,
-Jason
to create an object exactly like it, with it's properties and all, but have
it be a copy of the object passed through, and not just a reference to the
object.
Example:
Public Sub Form_Load(ByVal sender as Object, ByVal e as EventArgs)
Dim obj as Object = Activator.CreateInstance(Me.Tag.GetType())
obj = Me.Tag
When I say that obj = Me.Tag, then it only provides a reference to the
object in the Tag property. How can I create an exact duplicate instead?
TIA,
-Jason