Imports System.ComponentModel
Public Class ClassAsyncNodeBuild
    Private DTNODES As DataTable
    Private ImgList As ImageList
    Public WithEvents bw As BackgroundWorker
    Public newTreeview As TreeView

    Public Sub New(DT_TREEVIEW_NODES As DataTable, TREEVIEW_IMAGELIST As ImageList)
        Me.bw = New BackgroundWorker()
        bw.WorkerReportsProgress = False
        bw.WorkerSupportsCancellation = False
        Me.DTNODES = DT_TREEVIEW_NODES
        Me.ImgList = TREEVIEW_IMAGELIST
    End Sub

    Private Sub bw_DoWork(ByVal sender As Object, ByVal e As DoWorkEventArgs) Handles bw.DoWork
        Me.newTreeview = ClassNodeNavigation.CreateTreeViewNodes(DTNODES, ImgList)
    End Sub
End Class
