Cor,
Thanks for the link. This link gave me the answer I was looking for.
Thanks everyone else for he help too. For others who may reference this
question in the future, my final code is as follows:
Public Class Inmate
Private strName As String
Private strSSN As String
Private strDOB As String
Private myMugshotPicture() As MugshotPicture
Default Public Property myMugshotImage(ByVal index As Integer) As
MugshotImage
Get
Return CType(List(index), MugshotImage)
End Get
Set(ByVal Value As MugshotImage)
List(index) = Value
End Set
End Property
Public Function Add(ByVal value As MugshotImage) As Integer
Return List.Add(value)
End Function 'Add
Public Sub Remove(ByVal Value As MugshotImage)
Me.List.Remove(Value)
End Sub
End Class
Public Class MugshotPicture
Private strPictureName As String
Private strDateTaken As String
End Class
Calling code is as follows:
Dim myMugshotImage As New MugshotImage
myMugshotImage.strPictureName = "test"
Dim myInmate as new Inmate
myInmate.Add(myMugshotImage)
MessageBox.Show(myInmate.myMugshotImage(0).strPict ureName)
"Cor Ligthert" wrote:
Clearic,
Have a look at this page, it has a complete (a little bit complex) sample in
it.
http://msdn.microsoft.com/library/de...classtopic.asp
I hope this helps
Cor