Add javascript variable backgroundString and function onLoad() to the <head>
section:
var backgroundString;
function onLoad(){document.body.background=backgroundString }
In the html view write <body onload='onLoad()'>
In the code-behind write (c#)
Response.Write(String.Format("<script>backgroundSt ring={0}<script>",
dataitem));
Eliyahu
"Mike" <Mi**@discussions.microsoft.com> wrote in message
news:42**********************************@microsof t.com...
I want to change the background image of the html page within code based
on the users selection.
I'm trying to use this in the page onload even
response.write("<body background=' & dataitem>")
but i can't get it to work. if i hard code the dataitem in it will change
but i need it to work with the item being passed in.