Click to See Complete Forum and Search --> : saving stuff in listviews, URGENT!
BigWalrus
Jan 16th, 2000, 01:07 AM
does anyone know how to save the data underneath 'all' the column headers in report view to an external data file?
I want the data in the file to look like:
"title","author" etc
Joacim Andersson
Jan 16th, 2000, 07:55 PM
Here is an example that prints all the data. You can easily chage it so it prints the sText to a file instead:
Dim itmX As ListItem
Dim i%, iSubItemsCount%
Dim sText As String
For Each itmX In ListView1.ListItems()
sText = itmX.Text
iSubItemsCount = ListView1.ColumnHeaders.Count
For i = 1 To iSubItemsCount - 1
sText = sText & ", " & itmX.SubItems(i)
Next
Printer.Print sText
Next
Printer.EndDoc
Good luck!
------------------
Joacim Andersson
joacim@programmer.net
joacim@yellowblazer.com
www.YellowBlazer.com (http://www.YellowBlazer.com)
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.