Java.io.File.length() returns 0

Hi,
I have a applet where I need to check the size of a file on the hdd of the user.

Everything works, File.exists() returns true, but File.length() returns 0.

Is there a limitation, or some work around this?

I really need to know the size of the file, for download resume purposes, but can’t…

Thanks

May be you may already opened that file for writing if so it will return 0.