0

I'm a newbie to Asp.net,learning from the Apress's Begining Asp.net...book.While very curious to see an image given by me on the browser,I'm stuck at the very first step, please help.

Configuration : Win7(32-bit),VS2008 Pro/.net 3.5,Firefox as default browser.

Now,In created a simple website(not web app) in C#,added three images(.png,.jpg,.gif) to the App_Data folder(using the solutn. explorer of course).Then added the Image control from the toolbox & in the ImageUrl property, selected one of the images->presses f5 to start in debugging mode but every time the browser displays the alternate text given by me.

Whats the problem?

Thanks.

0

2 Answers 2

3

Don't put the image in the App_Data folder. Put it anywhere else in the website as anything inside the App_data folder is not accessible via HTTP Requests.

Sign up to request clarification or add additional context in comments.

Comments

1

App_Data is a protected directory.

Place your image somewhere else, suggestion : on root create the /images/ dir and place them there.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.