Click here to Skip to main content
15,849,494 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more: , +
Hello all,

Another newbie question using Visual Studio 2005, asp.net, c#.

I've got a smallish picture (pic1.jpg) that I want to use as a background for a web page (filling the entire screen with that image). I've created an App_LocalResources resource folder and placed pic1.jpg in it. In Properties, I set this image as the background and the following code is generated:

<body background="App_LocalResources/pic1.JPG">

In design mode, it works hunky-dory, but when I test it, the image is nowhere to be seen. I've tried different resource folders to no avail, so this is where I sit right now. Thanks.
Posted
Updated 17-May-13 4:42am
v2

1 solution

Try this
<body background="/App_LocalResources/pic1.JPG">

You can also use css refer following article
http://www.w3schools.com/css/css_background.asp[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900