sorry.
I didn't get this results, just assumed that it would b after few other expirements I did.
here is a 1 I've just tried:
//set %fileSize $file(abc.txt).size | //write abc.txt text | //echo -a $calc($file(abc.txt).size - %fileSize)
and I got
8.
when I tried 2 make it again- I got 6.
the file wasn't ending with $crlf on the 1st time so mIRC added this $crlf at the begining and at the end- so I got 8. this has nothing to do with the OS.
I was suggesting to add -n switch couz I didn't know it already in use (I am using older version of mIRC which don't have it).
but as I written in the new help file- the -n switch only prevents mIRC from adding $crlf to the end of the line- and not preventing mIRC to add it on the begining of the line.
here is what I got:
//bwrite abc.txt -1 -1 abc | set %fileSize $file(abc.txt).size | //write abc.txt text | //echo -a $calc($file(abc.txt).size - %fileSize)
echos 8.
anyway- after finding that my problem can b solved more easier than I tought with /bwrite I take my words back.
the suggestion about providing identifier to encode/decode utf-8/unicode strings remains. (if this not already added in newer versions than I have). The suggestion is to make mIRC to use the OS 2 provide those identifiers 4 scripters- even without any other internal support.
the suggestion from
multi threading also remains. I mean preventing from mIRC to freeze on any long operation. I am not talking about processing events- but about preforming what written in this operation...
here is an example:
$file(abc.dat).size is bigger than 1.5 Gb.
alias slowAlias {
var %i = 0
while (%i < $file(abc.dat).size) {
inc %i
bread abc.dat %i 1 &abc
bwrite abc.txt -1 -1 $chr($hget(assChar,$bvar(&abc,1)))
if ($right(%i,5) == 20000) echo -a now on $round($calc(%i / $file(abc.dat).size),1) $+ $chr(37) char $bytes(%i)
}
}
when I run /slowAlias from the command line- mIRC displays few lines with "now on..." and then freezes. after few minutes it returns to life and displays all the other messages.
it shouldn't b that way.
actually I didn't tried this alias- but that what would happen if I'd try.Tthe suggestion was to implement kind of multithreading but any other solution would b good also.
10x.