How to get the object's value passed in the dictionary object?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • shyammaggo
    New Member
    • Sep 2006
    • 1

    How to get the object's value passed in the dictionary object?

    How can I get the value of fo.filestatus and update it

    Code:
    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
            Dim fo As New fileDataType
            fo.filename = "File1"
            fo.filestatus = "processing"
            Try
                Dim fileStatus As New Dictionary(Of Integer, Object)
                fileStatus.Add(1, fo)
                MessageBox.Show(fileStatus.Item(1))
            Catch ex As Exception
            End Try
        End Sub
        Public Class fileDataType
            Public filename As String
            Public filestatus As String
        End Class
Working...