I am using this to save a file
dim f as folderItem
dim i as integer
dim t as textOutputStream
dim theLine as string
f = GetSaveFolderItem ("", "URL Database")
if f <> nil then
t = f.createTextFile
if t <> nil then
for i = 0 to window1.urlsv.listCount -1 //repeat with each row
of the listbox
theLine = window1.urlsv.cell(i,0) + chr(9) +
window1.urlsv.cell(i,1)
//theLine is made up of the Name + tab character + the URL
t.writeLine theLine
next
t.close
end if
end if
and this to open the file
dim i as integer
dim File as FolderItem
dim FileStream as TextInputStream
file=GetOpenFolderItem("")
If file <> Nil and file.exists then
FileStream = file.OpenAsTextFile
If FileStream <> Nil then
Do Until FileStream.EOF
window1.urlsv.AddRow FileStream.ReadLine
Loop
End
Else
MsgBox "File error"
End
The problem I am running into now is it shows the open dialog I
select a saved file and in the preview it shows that there is data in
that file but when I click open the data doesn't go into the window.
I am using a listbox I want to open the data and put it in a listbox
Brian
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>