Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Safe to have client-side AND server-side page load event procedures?

Reply
Thread Tools

Safe to have client-side AND server-side page load event procedures?

 
 
Fred
Guest
Posts: n/a
 
      07-12-2004
I'm combining the functionality of two existing aspx pages into one new
page.

One of the existing pages has a server-side Page_Load event procedure.
The other has <body onload="Init();"> (and Init() is of course a client-side
function).

Just wondering if it would be a mistake to try to have both of these
procedures (Page_Load and <body onload...>) in the new aspx page. Is there
anything wrong with doing it? Is it perfectly safe?

Thanks.


 
Reply With Quote
 
 
 
 
Curt_C [MVP]
Guest
Posts: n/a
 
      07-12-2004
perfectly acceptable. They are doing their thing at different times anyway.

--
Curt Christianson
Owner/Lead Developer, DF-Software
Site: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com


"Fred" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I'm combining the functionality of two existing aspx pages into one new
> page.
>
> One of the existing pages has a server-side Page_Load event procedure.
> The other has <body onload="Init();"> (and Init() is of course a

client-side
> function).
>
> Just wondering if it would be a mistake to try to have both of these
> procedures (Page_Load and <body onload...>) in the new aspx page. Is there
> anything wrong with doing it? Is it perfectly safe?
>
> Thanks.
>
>



 
Reply With Quote
 
 
 
 
Craig Deelsnyder
Guest
Posts: n/a
 
      07-12-2004
On Mon, 12 Jul 2004 11:38:51 -0700, Fred
<(E-Mail Removed)> wrote:

> I'm combining the functionality of two existing aspx pages into one new
> page.
>
> One of the existing pages has a server-side Page_Load event procedure.
> The other has <body onload="Init();"> (and Init() is of course a
> client-side
> function).
>
> Just wondering if it would be a mistake to try to have both of these
> procedures (Page_Load and <body onload...>) in the new aspx page. Is
> there
> anything wrong with doing it? Is it perfectly safe?
>
> Thanks.
>
>

They're totally separate from each other. The Page_Load is the ASP.NET
page's server side loading, while the other (body onload) is when the
resulting HTML page is loaded in the client browser. They completely
different 'concepts' and don't impact each other directly.

--
Craig Deelsnyder
Microsoft MVP - ASP/ASP.NET
 
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
firing button click event before page load event.....???? GauravGupta ASP .Net 4 01-19-2012 06:52 AM
Run Javascript function upon Page Load from Page Load event handle Matcon ASP .Net 3 05-28-2008 05:15 PM
Page Load and webcontrol page load venky ASP .Net 5 07-11-2005 03:16 PM
Inherited Page Always Calls Base Page Load Event WFB ASP .Net 1 12-30-2003 10:32 PM
$SAFE = 5 and Safe Ruby Misleading? kirindave@lensmen.net Ruby 1 08-11-2003 11:35 PM



Advertisments