Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Body Onload

Reply
Thread Tools

Body Onload

 
 
Arne Garvander
Guest
Posts: n/a
 
      09-25-2008
I have an asp.net page with a master page.
How do I dynamically create an HTML body onload event?
<body onload="CalcTotal()";

--
Arne Garvander
(I program VB.Net for fun and C# to get paid.)
 
Reply With Quote
 
 
 
 
Nathan Sokalski
Guest
Posts: n/a
 
      09-25-2008
If you give the body tag an id and runat="server" you can do it from either
the Master Page's Load or Init event or the Content Page's PreInit event.
You will do this by using the body tag's Attributes property. Good Luck!
--
Nathan Sokalski
http://www.velocityreviews.com/forums/(E-Mail Removed)
http://www.nathansokalski.com/

"Arne Garvander" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
>I have an asp.net page with a master page.
> How do I dynamically create an HTML body onload event?
> <body onload="CalcTotal()";
>
> --
> Arne Garvander
> (I program VB.Net for fun and C# to get paid.)



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
onload -->* no onload marco Javascript 7 06-24-2006 08:39 PM
Adding a onload event to the body section. UJ ASP .Net 4 07-19-2005 09:15 PM
Why doesn't frameset onload event get called when each of the frames has an onload? adnanx82@gmail.com Javascript 5 05-15-2005 01:58 PM
base.OnLoad called, OnLoad not executed Fabio R. ASP .Net 0 03-25-2005 01:21 PM
window.onload and body.onload differences David Otton Javascript 2 11-04-2004 04:34 PM



Advertisments