Using FolderBrowserDialog As New FolderBrowserDialog
If FolderBrowserDialog.ShowDialog = Windows.Forms.DialogResult.OK Then
Dim 资料夹 As String() = System.IO.Directory.GetFiles(FolderBrowserDialog.SelectedPath, "*")
For Each 文件 In 资料夹
MsgBox(My.Computer.FileSystem.ReadAllText(文件)) '读取数据
My.Computer.FileSystem.WriteAllText(文件, "数据", False) '写入数据
Next
End If
End Using