how to compare file chars with bytes?

Mark Schonewille m.schonewille at economy-x-talk.com
Sat Jan 17 14:57:22 EST 2009


Hi Tiemo,

The number of chars of a text file and the number of bytes of that  
file are equal, if you read the file as binary data. Are you sure that  
you have the file size correct? What numbers do you get? You might  
want to post the relevant part of your script.

--
Best regards,

Mark Schonewille

Economy-x-Talk Consulting and Software Engineering
http://economy-x-talk.com
http://www.salery.biz
Dutch forum: http://runrev.info/rrforum

We are always looking for new projects! Feel free to contact us to  
discuss your custom software project!

On 17 jan 2009, at 20:14, Tiemo Hollmann TB wrote:

> Hello,
>
> sorry for this perhaps stupid question. I want to show a progress  
> bar while
> reading a file in chunks of chars in a repeat loop.
>
> Filtering first the total number of bytes out of the detailed files  
> info I
> thought I could easily set the read chars in relation of the total  
> bytes,
> thinking that the number of chars is roughly equivalent to the  
> number of
> bytes, beside of some overhead here and there, but the numbers are
> completely different.
>
> Obviously I am missing some basics here, but there should be a simple
> solution for this standard issue?
>
> Thanks for correcting me
>
> Tiemo
>




More information about the Use-livecode mailing list