How to use ItemList Box to
Display a Text File or Contents of a Text File
Keywords: itembox askfiletext file text
Question:
How might I go about using ItemList Box to
display a text file?
Answer:
- If all you want to do is display the file, use AskFileText.
- Otherwise...
fname="c:\temp\example.txt" ; your file
fsize=FileSize(fname)
bb=BinaryAlloc(fsize)
BinaryRead(bb,fname)
filetext=BinaryPeekStr(bb,0,fsize)
BinaryFree(bb)
Now use the filetext variable in your Dialog ItemBox.
Article ID: W12839
Filename: Displaying Contents of a File in ItemBox.txt