Load image

N

nuhura01

Hi all...

My system contains an image which I have saved it at client side.
Unfortunately, when users want to view the image, the image doesn't
loaded. If i'm not mistaken, it is set at the HTML code of asp.net web
form right? I've set the Image URL to be like this:
ImageUrl="C:\ExportImage.gif".

I don't want to create a new file for placing the image since other
clients who don't have the file might not be able to access the image.
I also don't want to save it at server side since it may cause an
error if more clients want to access the same image at the same time.
How could I do this? Can anyone help me...

Thanks...
 
G

Guest

Hi all...

My system contains an image which I have saved it at client side.
Unfortunately, when users want to view the image, the image doesn't
loaded. If i'm not mistaken, it is set at the HTML code of asp.net web
form right? I've set the Image URL to be like this:
ImageUrl="C:\ExportImage.gif".

This is wrong. It's your C-drive.

The image should be on the server, e.g. where you aspx form is
located.

then the image url will be

ImageUrl="ExportImage.gif"

I don't want to create a new file for placing the image since other
clients who don't have the file might not be able to access the image.
??

I also don't want to save it at server side since it may cause an
error if more clients want to access the same image at the same time.

In this case the aspx form with link to image will be not available as
well, don't you think? :)

This is wrong... image should be on the server. ASP means Active
SERVER Pages and must be served by the server.
 
P

Peter Bradley

I'm not sure I entirely understand your query; but I would be interested to
know why you think there would be any contention if the image was stored
server side?

An image in a web page will load when the rendering engine meets an <img>
tag. So to load an image you need something like <img src="path/to/image"
/>

Am I missing something here?


Peter
 
D

David

Hi all,

I think an example that the OP asked for could be something like a portlet
or something that the client has defined an image on their own hard disk
that they want to view. This is fairly valid as a path to the image in an
IMG tag, but may not render correctly in ImageUrl.

What the OP could try is file://c:\image.jpg

(You may need to do file://c:\\image.jpg to make it work though in your
..ImageUrl)

Hope it helps.

Best regards,
Dave Colliver.
http://www.DerbyFOCUS.com
~~
http://www.FOCUSPortals.com - Local franchises available
 
N

nuhura01

Hi all...

My system contains an image which I have saved it at client side.
Unfortunately, when users want to view the image, the image doesn't
loaded. If i'm not mistaken, it is set at the HTML code of asp.net web
form right? I've set the Image URL to be like this:
ImageUrl="C:\ExportImage.gif".

I don't want to create a new file for placing the image since other
clients who don't have the file might not be able to access the image.
I also don't want to save it at server side since it may cause an
error if more clients want to access the same image at the same time.
How could I do this? Can anyone help me...

Thanks...

Yeah, may be you are right. Sorry... I'm very new with asp.net and
still learning on that...
So, what should I do if I want to load the image that is located at
the C-drive? I've tried to set the image url as

ImageUrl="ExportImage.gif"

but it seems doesn't work. Any suggestions?

Thanks in advance..
 
N

nuhura01

This is wrong. It's your C-drive.

The image should be on the server, e.g. where you aspx form is
located.

then the image url will be

ImageUrl="ExportImage.gif"




In this case the aspx form with link to image will be not available as
well, don't you think? :)

This is wrong... image should be on the server. ASP means Active
SERVER Pages and must be served by the server.





- Show quoted text -

Yeah, may be you are right. Sorry... I'm very new with asp.net and
still learning on that...
So, what should I do if I want to load the image that is located at
the C-drive? I've tried to set the image url as

ImageUrl="ExportImage.gif"

but it seems doesn't work. Any suggestions?

Thanks in advance..
 
G

Guest

So, what should I do if I want to load the image that is located at
the C-drive?

I think you don't understand a basic principles...

Why do you want to load it from the C-drive? It should be from the
server...

As far as I know a link to file://c:\\image.jpg will not work by
default since XP SP2 (file:// is blocked by default) and there is
absolutely no way to link to the image on a client without changing
the security settings on the client.

I've tried to set the image url as
ImageUrl="ExportImage.gif"
but it seems doesn't work.

By using ImageUrl="ExportImage.gif" you refer to ExportImage.gif
located in the same directory where the ASPX form is located. You have
to copy ExportImage.gif to the same directory.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,898
Latest member
BlairH7607

Latest Threads

Top