|
これでどうでしょーか ?
Sub Mk_MyText()
Dim i As Long
Dim Ary As Variant, Ary2 As Variant
Dim MyF As String, Buf As String
MyF = Application.DfaultFilePath & "\Test.txt"
If Dir(MyF) <> "" Then Kill MyF
Open MyF For OutPut Acess Write As #1
For i = 1 To Range("A65536").End(xlUp).Row
Ary = Cells(i, 1).Resize(, 3).Value
With WorksheetFunction
Ary2 = .Transpose(.Transpose(Ary))
End With
Buf = Join(Ary2, "*")
Print #1, Buf
Erase Ary, Ary2
Next i
Close #1
With Application
ChDir .DfaultFilePath
.Dialogs(xlDialogOpen).Show Arg1:="Test.txt"
End With
End Sub
|
|