it's easier to parse a 

get shell("dir" && yourpath)

or to avoid reading the file completely in ram,

open file x for reading
put 0 into filesize
put 1024 into buffersize
repeat
read from file x for buffersize
if it is empty then exit repeat
get length of it
if it is not buffersize then
  add it to filesize
  exit repeat
else add buffersize to filesize
end repeat
close file x

> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]]On Behalf Of LiangTyan Fui
> Sent: Wednesday, May 16, 2001 3:38 AM
> To: [EMAIL PROTECTED]
> Subject: Re: size of a file/URL
> 
> 
> On 5/15/01 11:53 PM, Leston Drake wrote:
> 
> > A simple question,
> > 
> > Does anyone know of a way to find out the size of a file (in Windows)?
> 
> put length(url "file:yourfile")
> 
> Beware though MetaCard will read the entire file "yourfile" into RAM before
> counting it ;-)
> 
> Regards,
> LiangTyan Fui
> 
> 
> Archives: http://www.mail-archive.com/[email protected]/
> Info: http://www.xworlds.com/metacard/mailinglist.htm
> Please send bug reports to <[EMAIL PROTECTED]>, not this list.
> 
> 

Archives: http://www.mail-archive.com/[email protected]/
Info: http://www.xworlds.com/metacard/mailinglist.htm
Please send bug reports to <[EMAIL PROTECTED]>, not this list.

Reply via email to