Sign in to follow this  
Followers 0
Starfighter

InetGetSize function works differing

3 posts in this topic

Hello Programmers,

I have a problem with the InetGetSize function:

$FileInternetMain="http://imdb.com/"

$SizeOfFileInternetMain=InetGetSize($FileInternetMain)

MsgBox(0,"SizeOfFileInternetMain","*" & $SizeOfFileInternetMain & "*")

The size is always 0 bytes!

It seems this code doesn't work.

But this following code work fine:

$FileInternetMain="http://i.imdb.com/images/nb15/logo.gif"

$SizeOfFileInternetMain=InetGetSize($FileInternetMain)

MsgBox(0,"SizeOfFileInternetMain","*" & $SizeOfFileInternetMain & "*")

The size is 5596 bytes.

How can I determine the size from "http://imdb.com/" correctly?

Share this post


Link to post
Share on other sites



Returns the size (in bytes) of a file located on the internet.

I don't think it says anything about "directories" there.


Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post


Link to post
Share on other sites

Yeah, the problem is you have given it a directory. Whereas in the second example it has been given a file.

You could perhaps try an InetGetSource() and save the source.. but that is not going to get you the sizes of all images etc. Just the size of the html code that is produced.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0