Count number of lines in file.
Posted: Sun Mar 24, 2013 7:50 pm
Hi all,
Just started programming with Livecode and really enjoying myself. My first application is a proof of concept for a small and cheap data com app to be used in a taxi system. It took me about a day to get things running but one line of code keeps giving me a lot of problems,
get the number of lines of URL "http: // www mobiportal nl/ritten.txt"
put it into cUbound
The file to be read is on our web server and its contents is al list of trips for a specific day. In order to loop through the file, and make choices as enable next button etc, i need the number of lines in the file. The code above the line functions about 40% of the times its called an gives back 189, the correct number of lines in the file. The other 60% it returns a 0. I have read some forum articles about networking problems and test with some code changes but no result.
Anyone a suggestion where i, or LC are making an error?
Thanks,
Pedro Prevost
Just started programming with Livecode and really enjoying myself. My first application is a proof of concept for a small and cheap data com app to be used in a taxi system. It took me about a day to get things running but one line of code keeps giving me a lot of problems,
get the number of lines of URL "http: // www mobiportal nl/ritten.txt"
put it into cUbound
The file to be read is on our web server and its contents is al list of trips for a specific day. In order to loop through the file, and make choices as enable next button etc, i need the number of lines in the file. The code above the line functions about 40% of the times its called an gives back 189, the correct number of lines in the file. The other 60% it returns a 0. I have read some forum articles about networking problems and test with some code changes but no result.
Anyone a suggestion where i, or LC are making an error?
Thanks,
Pedro Prevost