All this part does is show the dialog and get the file name.
But the file name is something way off in lala land. Odd part, the file it shows doesn't work on my 64 bit system, but the file that it's supposed to locate does.
vb Code:
Select Case Locater.ShowDialog()
Case DialogResult.OK
If IO.File.Exists(Locate.FileName) Then
XML_Remove_Item(list:=list, address:=address, bMissing:=True)
'Grab the current user control UserList from the display panel
Dim ucList As UserList = DirectCast(MainForm.pnlList.Controls.Item(MainForm.pnlList.Controls.IndexOfKey("lView")), UserList)
'Create a new listviewitem to be displayed in ucList
Dim item As New ListViewItem
'Extract icon from file
Dim extractor As New IconExtractor
ucList.IM1.Images.Add(extractor.Extract(Locate.FileName, IconSize.Large))
'Set the text of the new listviewitem to be the name of the program
'without extension or path information
item.Text = IO.Path.GetFileNameWithoutExtension(Locate.FileName)
'Set the image index integer
item.ImageIndex = ucList.iImages
'set the tag to the file including path and extension
item.Tag = Locate.FileName
'Set the text to white
item.ForeColor = Color.White
'Add the item to ucList
ucList.lvList.Items.Add(item)
'Raise image index for later usage
ucList.iImages += 1
Write_Data_Item(list:=list, address:=Locate.FileName)
End If
Case DialogResult.Cancel
XML_Remove_Item(list:=list, address:=address, bMissing:=True)
End Select