Suppose you want to Export a set of Data to an Excel format. In this case we are using a .csv file
Suppose you want to Export a set of Data to an Excel format. In this case we are using a .csv file (which opens in Excel). We found itVery
Rate Suppose you want to Export a set of Data to an Excel format. In this case we are using a .csv file
(1(1 Vote))
On Error Resume Next
Adodc1.Refresh
c = 0
Open app.Path & "\LISTEX.csv" For Append As #1
Write #1, c, Label1, Label2, Label3, Label4, Label5, Label6, Label7, Label8
Close #1
Do While Not Adodc1.Recordset.EOF
c = c + 1
Call textfile
Adodc1.Recordset.MoveNext
Loop
If Adodc1.Recordset.EOF = True Then Adodc1.Refresh
MsgBox "Your csv file is ready. CLICK 'OPTIONS / View csv File to see the file you have created."
Frame1.Visible = False
End Sub
Private Sub textfile()
'allows you to make headers
Open app.Path & "\LISTEX.csv" For Append As #1
Write #1, c, Adodc1.Recordset.Fields(Label1.Caption), Adodc1.Recordset.Fields(Label2.Caption), Adodc1.Recordset.Fields(Label3.Caption), Adodc1.Recordset.Fields(Label4.Caption), Adodc1.Recordset.Fields(Label5.Caption), Adodc1.Recordset.Fields(Label6.Caption), Adodc1.Recordset.Fields(Label7.Caption), Adodc1.Recordset.Fields(Label8.Caption)
Close #1
End Sub
Suppose you want to Export a set of Data to an Excel format. In this case we are using a .csv file Comments
No comments yet — be the first to post one!
Post a Comment