This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Read ascending lines in text file

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
s
sleeplezz
Voice
Posts: 7
Joined: Sun Jun 04, 2006 12:13 pm

Read ascending lines in text file

Post by sleeplezz »

Hi! I'm a newbie on tcl scripting and I like to request a text reader tcl. :)

I need a tcl to read every lines in a text file then post it to a channel every x seconds. But it should be read ascending ( not random ) from the first line to the next lines until the end of file then doing re-reading if tcl finished read a whole lines in that file.

My text file contain lines like this ...
...
- June, 2th 2006 - Our site was updated, so pls check it out guys!
- June, 3rd 2006 - Team agreed to make a dinner, pls contact Jim for info.
- June, 4th 2006 - Carey b'day is on next Sunday, don't forget to attend it!
...
Got an idea to help me ? :) Thanks in advance!
User avatar
De Kus
Revered One
Posts: 1361
Joined: Sun Dec 15, 2002 11:41 am
Location: Germany

Post by De Kus »

You want to be to post each new line since it last checked? Or always post the whole file? And where is the problem about random? Search the forums, there are plenty solutions to split \n and foreach each line... even with increasing timers to delay output addionally to puthelp queue.
De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens...
s
sleeplezz
Voice
Posts: 7
Joined: Sun Jun 04, 2006 12:13 pm

Post by sleeplezz »

It will post a whole lines on file. I found many post about text file reading... I need to checked all of them. Any suggestions are welcome. Thanks.
Post Reply