Hello guys,
i will read an very long line in Files how i can do this ?
greetings
juergen
filename = "E:\a\Projekt GL NEU\FB\bed.htm"
arrFile = ArrayFileGet (filename , "" , 0)
linecount = ArrInfo(arrFile,6)
For x = 0 to linecount-1
line = arrFile
Pause("Line: ":x, line)
Next
The solution depends on what exactly the "this" is you are trying to perform. If you are referring to parsing out the contents of a file, WinBatch offers several ways of performing that task including loading the file into a binary buffer. If you are referring to displaying the contents of a portion of a file, WinBatch offers several ways of performing that task too. For example, you could consider creating a WIL dialog.
Also, you can control the maximum file line length with IntControl 65. Check it out in the Consolidated WIL Help file on your system or by going to the WinBatch Documentation Website.
intcontrol 65?
Jim
Maybe off topic. But why read an .htm file line by line. There are parsers and components that might produce results [not specified in original post]... conducive to a goal.
Quote from: JTaylor on June 02, 2022, 07:04:12 AM
intcontrol 65?
Jim
It is in the help file and ...
https://docs.winbatch.com/mergedProjects/WindowsInterfaceLanguage/html/WILAK_I__086.htm (https://docs.winbatch.com/mergedProjects/WindowsInterfaceLanguage/html/WILAK_I__086.htm)
At the risk of speaking the obvious, IntControl 65 documentation only mentions the FileRead function but the same setting is used by ArrayFileGet. A new IntControl 65 setting only takes effect for files opened with FileOpen or ArrayFileGet after the call to IntControl 65.