Dim mydirpath As String = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments) Dim txtlist As String() = Directory.GetFiles(mydirpath, "*.doc") Dim strfile As New StringBuilder Dim txtname As String For Each txtname In txtlist Using sr As New StreamReader(txtname) strfile.AppendLine(txtname.ToString()) strfile.Append(sr.ReadToEnd()) strfile.AppendLine() End Using Next Using outfile As New StreamWriter(mydirpath + "\output.doc") outfile.Write(strfile.ToString()) End Using
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)