I have several classes implementing the same interface, let's call it "IMyData".
In the following method I want to copy the IMyData data from an object to
a new object of different type but implementing the same common interface
The rest of the question is inline in the following function example:
Public Sub AddObjectToControl(ByVal Data As IMyData)
Dim MLI As New MyListItem()
Now I wan't to assign all the properties in IMyData
to CType(MLI,IMyData). Is there some better (shorter) way to do
this than assigning each property separately like this?
MLI.Property1 = Data.Property1
MLI.Property2 = Data.Property2
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL