Dim i,fso,f,DataSet,FName
[COLOR=#0000ff][COLOR=#0000ff]Const[/COLOR][/COLOR] ForReading = 1, ForWriting = 2, ForAppending = 8
[COLOR=#0000ff][COLOR=#0000ff]FName="d:\"+CStr(Date)+".csv"
Set[/COLOR][/COLOR] fso = CreateObject ("Scripting.FileSystemObject")
[COLOR=#0000ff][COLOR=#0000ff]If[/COLOR][/COLOR] [COLOR=#0000ff][COLOR=#0000ff]Not[/COLOR][/COLOR] fso.FileExists ([COLOR=#0000ff]FName[/COLOR]) [COLOR=#0000ff][COLOR=#0000ff]Then
[/COLOR][/COLOR][COLOR=#0000ff][COLOR=#0000ff] Set[/COLOR][/COLOR] f = fs.OpenTextFile(FName, ForWriting, [COLOR=#0000ff][COLOR=#0000ff]true[/COLOR][/COLOR])
[COLOR=#0000ff][COLOR=#0000ff]Else
[/COLOR][/COLOR][COLOR=#0000ff][COLOR=#0000ff] Set[/COLOR][/COLOR] f = fso.OpenTextFile(FName, ForAppending)
[COLOR=#0000ff][COLOR=#0000ff]End[/COLOR][/COLOR] [COLOR=#0000ff][COLOR=#0000ff]If[/COLOR][/COLOR]
[FONT=Times New Roman][SIZE=3]DataSet = CStr(Now) & ";"[/SIZE][/FONT]
[FONT=Times New Roman][SIZE=3]for i = 1 to Anzahl[/SIZE][/FONT]
[FONT=Times New Roman][SIZE=3] DataSet = DataSet & [/SIZE][/FONT][FONT=Times New Roman][SIZE=3]CStr(Variable_2(i)) & ";"[/SIZE][/FONT]
[FONT=Times New Roman][SIZE=3]next[/SIZE][/FONT]
[FONT=Times New Roman][SIZE=3]f.WriteLine DataSet
f.close[/SIZE][/FONT]