Private Sub LadenToolStripMenuItem_Click(sender As Object, e As EventArgs) Handles LadenToolStripMenuItem.Click ListView1.Items.Clear() ListView2.Items.Clear() ListView3.Items.Clear() ListViewLoad(ListView1, "C:\Users\Tim_\Documents\list") ListViewLoad2(ListView2, "C:\Users\Tim_\Documents\list2") ListViewLoad3(ListView3, "C:\Users\Tim_\Documents\list3") Dim rd As New System.IO.StreamReader("C:\Users\Tim_\Documents\list4") tb1.Text = rd.ReadLine tb2.Text = rd.ReadLine tb3.Text = rd.ReadLine tb4.Text = rd.ReadLine tb5.Text = rd.ReadLine tb6.Text = rd.ReadLine tb7.Text = rd.ReadLine tb8.Text = rd.ReadLine rd.Close() End Sub Public Function ListViewSave(ByRef LstVw As ListView, ByVal Path As String) Dim ListViewContent As String = "" For I As Integer = 0 To LstVw.Items.Count - 1 ListViewContent += LstVw.Items.Item(I).Text & "##" For Int As Integer = 0 To LstVw.Items.Item(I).SubItems().Count - 1 ListViewContent += LstVw.Items.Item(I).SubItems(Int).Text & "##" Next ListViewContent += vbNewLine Next If System.IO.File.Exists(Path) Then System.IO.File.Delete(Path) End If System.IO.File.AppendAllText(Path, ListViewContent) End Function Public Function ListViewSave2(ByRef LstVw As ListView, ByVal Path As String) Dim ListViewContent As String = "" For I As Integer = 0 To ListView2.Items.Count - 1 ListViewContent += ListView2.Items.Item(I).Text & "##" For Int As Integer = 0 To ListView2.Items.Item(I).SubItems().Count - 1 ListViewContent += ListView2.Items.Item(I).SubItems(Int).Text & "##" Next ListViewContent += vbNewLine Next If System.IO.File.Exists(Path) Then System.IO.File.Delete(Path) End If System.IO.File.AppendAllText(Path, ListViewContent) End Function Public Function ListViewSave3(ByRef LstVw As ListView, ByVal Path As String) Dim ListViewContent As String = "" For I As Integer = 0 To ListView3.Items.Count - 1 ListViewContent += ListView3.Items.Item(I).Text & "##" For Int As Integer = 0 To ListView3.Items.Item(I).SubItems().Count - 1 ListViewContent += ListView3.Items.Item(I).SubItems(Int).Text & "##" Next ListViewContent += vbNewLine Next If System.IO.File.Exists(Path) Then System.IO.File.Delete(Path) End If System.IO.File.AppendAllText(Path, ListViewContent) End Function Public Function ListViewLoad(ByRef LstVw As ListView, ByVal Path As String) Dim sLine As String Dim sItem() As String Dim ItemX As ListViewItem Dim IntCols As Integer IntCols = LstVw.Columns.Count FileOpen(1, Path, OpenMode.Input) With LstVw.Items While Not EOF(1) sLine = LineInput(1) sItem = Split(sLine, "##") ItemX = .Add(sItem(0), sItem(1)) For i = 2 To IntCols ItemX.SubItems.Add(sItem(i)) Next i End While End With FileClose(1) End Function Public Function ListViewLoad2(ByRef LstVw As ListView, ByVal Path As String) Dim sLine As String Dim sItem() As String Dim ItemX As ListViewItem Dim IntCols As Integer IntCols = ListView2.Columns.Count FileOpen(1, Path, OpenMode.Input) With ListView2.Items While Not EOF(1) sLine = LineInput(1) sItem = Split(sLine, "##") ItemX = .Add(sItem(0), sItem(1)) For i = 2 To IntCols ItemX.SubItems.Add(sItem(i)) Next i End While End With FileClose(1) End Function Public Function ListViewLoad3(ByRef LstVw As ListView, ByVal Path As String) Dim sLine As String Dim sItem() As String Dim ItemX As ListViewItem Dim IntCols As Integer IntCols = ListView3.Columns.Count FileOpen(1, Path, OpenMode.Input) With ListView3.Items While Not EOF(1) sLine = LineInput(1) sItem = Split(sLine, "##") ItemX = .Add(sItem(0), sItem(1)) For i = 2 To IntCols ItemX.SubItems.Add(sItem(i)) Next i End While End With FileClose(1) End Function