|
あー・・つまり私の最初のレスで提示した"Test_Write"プロシージャに対して、
そのようなダイアログを出すように変更したい、ということですね ?
ならば
Sub Test_Write2()
Dim A As Integer, B As Integer
Dim C As Integer, D As Integer, E As Integer
Dim Ary As Variant
Dim Buf As String, MyF As String
ChDir "C:\Documents and Settings\User\My Documents"
'↑保存先のパスにする
MyF = Application _
.GetSaveAsFilename("","テキスト ファイル(*.txt),*.txt")
If MyF = "False" Or MyF = "" Then Exit Sub
A = 10: B = 11: C = 12: D = 0: E = -12
Ary = Array(A, B, C, D, E)
Buf = Join(Ary, ",")
Open MyF For OutPut Access Write As #1
Print #1, Buf
Close #1
ChDir Application.DefaultFilePath
MsgBox MyF & vbLf & "を作成・保存しました", 64
End Sub
|
|