Body onLoad Problem (ASP .NET & JavaScript)

C

ceolino

Hi all.
I have a simple default.aspx file where I declare a JavaScript
function:

<script type="text/javascript" language="JavaScript">
....
function rotate() {
....
}
</script>
</head>

and, after that, I insert

<body ID="body1" runat="server">.

So, this is my problem: why does the validator tell me that "body1 is
not a member of _default" (error BC30456) if in default.aspx.vb I write
the following statement?

Me.body1.Attributes.Add("onLoad", "rotate()")

What I am trying to do is to call "rotate" function on body load..can
anyone help me?

Thanks in advance!!
 

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

Forum statistics

Threads
473,767
Messages
2,569,572
Members
45,045
Latest member
DRCM

Latest Threads

Top