我尝试制作一个可以在一行中显示所有项目的数组列表。
Dim listarray As New ArrayList
Dim JARLIB As String = "*.jar"
Dim dir As New IO.DirectoryInfo(GetFolderPath(SpecialFolder.ApplicationData) & "\.minecraft\libraries\")
Dim diarr1() As IO.FileInfo = dir.GetFiles(JARLIB, SearchOption.AllDirectories)
Dim drar As IO.FileInfo
'list the names of all files in the specified directory
For Each drar In diarr1
listarray.Add((drar.DirectoryName) & ";")
Next
elemante = listarray.ToString
RichTextBox1.Text = elemante
那是行不通的,我必须在 TextBox 中接收类似
C:\User\file.jar;C:\User\file\file2.jar;
你能帮助我吗 ?谢谢 !