Help | Site Map
Connecting Tech Pros Worldwide
 
 
LinkBack Thread Tools
  #1  
Old July 19th, 2005, 10:58 AM
ËιúÐû
Guest
 
Posts: n/a
Default How to get the image size?

How to get the image size with VBScript in ASP?


  #2  
Old July 19th, 2005, 10:58 AM
Mortis the Rigger
Guest
 
Posts: n/a
Default How to get the image size?

What type of image is it, gif, jpg, png etc etc!!!

Details my man, Details!!! :)
[color=blue]
>-----Original Message-----
>How to get the image size with VBScript in ASP?
>
>
>.
>[/color]
  #3  
Old July 19th, 2005, 10:58 AM
Mikhail Tchikalov
Guest
 
Posts: n/a
Default Re: How to get the image size?

You can use the GetFileDimensions method of Shotgraph component:
http://www.shotgraph.com
It returns both image type and dimensions.

Best regards,
Mikhail.


<dellsoncomp@126.com> wrote in message
news:O0PGfdc1DHA.2324@TK2MSFTNGP09.phx.gbl...[color=blue]
> How to get the image size with VBScript in ASP?
>
>[/color]


  #4  
Old July 19th, 2005, 10:58 AM
William Morris
Guest
 
Posts: n/a
Default Re: How to get the image size?

This is a subject that's come up many many times in the various asp
newsgroups. Take a look here, as well:

http://www.aspfaq.com/show.asp?id=2170


"ËιúÐû" <dellsoncomp@126.com> wrote in message
news:O0PGfdc1DHA.2324@TK2MSFTNGP09.phx.gbl...[color=blue]
> How to get the image size with VBScript in ASP?
>
>[/color]


  #5  
Old July 19th, 2005, 11:00 AM
Roland Hall
Guest
 
Posts: n/a
Default Re: How to get the image size?

"Mortis the Rigger" wrote:
: What type of image is it, gif, jpg, png etc etc!!!
:
: Details my man, Details!!! :)

*snicker*


  #6  
Old July 19th, 2005, 11:00 AM
Roland Hall
Guest
 
Posts: n/a
Default Re: How to get the image size?

"ËιúÐû" write:
: How to get the image size with VBScript in ASP?

1. Define 'image size'. Do you want width and height or file size?
2. Do you want this from the local drive, i.e. with ASP Upload prior to
upload, or do you want it from an image on the server?

I can get the file size, width, and height either from local or server
without components and without using FSO.
Please advise.

--
Roland

This information is distributed in the hope that it will be useful, but
without any warranty; without even the implied warranty of merchantability
or fitness for a particular purpose.
-Technet Knowledge Base-
http://support.microsoft.com/default...&ln=EN-US&FR=0
-Technet Script Center-
http://www.microsoft.com/technet/tre...er/default.asp
-MSDN Library-
http://msdn.microsoft.com/library/default.asp


  #7  
Old July 19th, 2005, 11:00 AM
Dan Boylett
Guest
 
Posts: n/a
Default Re: How to get the image size?


"Roland Hall" <nobody@nowhere> wrote in message
news:eFZKojp1DHA.2408@tk2msftngp13.phx.gbl...
[color=blue]
> I can get the file size, width, and height either from local or server
> without components and without using FSO.[/color]

How do you manage that then? I would have assumed you'd need to use the FSO
to get information about a file.





  #8  
Old July 19th, 2005, 11:00 AM
Roland Hall
Guest
 
Posts: n/a
Default Re: How to get the image size?

"Dan Boylett" wrote:
: "Roland Hall" <nobody@nowhere> wrote in message
: news:eFZKojp1DHA.2408@tk2msftngp13.phx.gbl...
:
: > I can get the file size, width, and height either from local or server
: > without components and without using FSO.
:
: How do you manage that then? I would have assumed you'd need to use the
FSO
: to get information about a file.

On the server-side you do if it is not an image file. If it is an image
file you can create a new image and set the src to your image file. You
then can use fileSize but there is an issue. When I do it quickly, it
displays -1 for fileSize. If I introduce a delay, it works.

This is one I wrote that allows you to check the file size and image size
(width/height) before you upload. It has a flaw because it will not clear
the file upload text if the file fails validation so I'm using an
alternative method for submitting the form with valid files. I got a
response from HikksNotAtHome about using a dummy form but I have not put in
his method with this code yet.

This is the link for the client-side code:
http://kiddanger.com/lab/iupload.asp

This is the link of the other discussion:
http://groups.google.com/groups?hl=e...phx.gbl#link18


 

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over network members.
Post your question now . . .
It's fast and it's free

Popular Articles