[Gambas-user] read a file into a listview - but backwards

Stefano Palmeri rospolosco at ...152...
Thu Apr 30 23:59:43 CEST 2009


Il giovedì 30 aprile 2009 19:46:25 Joshua Higgins ha scritto:
> Hi all,
>
> Is it possible to read a file and load it line by line into a listview, but
> backwards? I have been using the example from gambasdoc for loading files
> line by line, but I'm writing a logging page and want to show newest items
> first.
>
> Thanks.

Or you can using the magic of shell:

Dim sReverseFile as String

SHELL "tac " & PathToFile TO sReverseFile

then load sReverseFile. If file is big consider
creating a temporary file for redirecting 'tac' to.

Saluti,

Stefano 




More information about the User mailing list