473,406 Members | 2,377 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Confused with autoeventwireup

I read that autoeventwireup="false" doesn't cause Page_Load to fire
automatically and trying it out with a simple page this can be confirmed
easily.
However, I have a page with autoeventwireup="false" (that has a masterpage
with autoeventwireup="false" as well) and Page_Load DOES fire in the page.
How can this be ? Other pages using the same Master page does NOT fire
Page_Load, unless I wire up the event manually.
I'm totally confused. Moreover, this specific page fires Page_Load and all
other events TWICE.
Aug 25 '06 #1
5 1501
If this is the only page with the problem, then clearly something is
different about this page. There must be something else going on there, some
other difference, some other code running that is causing this on the one
particular page, while all other pages are fine.

You should carefully examine all the differences between this page and the
others, as well as remove unecessary pieces of code to really boil it down
to what the problem is.

"Carlo Marchesoni" <Ca*************@discussions.microsoft.comwrote in
message news:C0**********************************@microsof t.com...
>I read that autoeventwireup="false" doesn't cause Page_Load to fire
automatically and trying it out with a simple page this can be confirmed
easily.
However, I have a page with autoeventwireup="false" (that has a masterpage
with autoeventwireup="false" as well) and Page_Load DOES fire in the page.
How can this be ? Other pages using the same Master page does NOT fire
Page_Load, unless I wire up the event manually.
I'm totally confused. Moreover, this specific page fires Page_Load and all
other events TWICE.

Aug 25 '06 #2
Carlo Marchesoni wrote:
I read that autoeventwireup="false" doesn't cause Page_Load to fire
automatically and trying it out with a simple page this can be confirmed
easily.
However, I have a page with autoeventwireup="false" (that has a masterpage
with autoeventwireup="false" as well) and Page_Load DOES fire in the page.
How can this be ? Other pages using the same Master page does NOT fire
Page_Load, unless I wire up the event manually.
I'm totally confused. Moreover, this specific page fires Page_Load and all
other events TWICE.

Have you explicitly wired the event up? Is this an ASP 1.1 page or 2.0?

Kevin
Aug 25 '06 #3
It is an ASP 2.0 page (sorry, I should have mention it).
The strange thing that I DID NOT WIRE up the page load event - that's
exactly the thing I do not understand. autoeventwireup=false (even on the
masterpage), some usercontrols which also have autoeventwireup=false, no
wire-up and Page_Load is fired (even twice !!)

"Kevin Jones" wrote:
Carlo Marchesoni wrote:
I read that autoeventwireup="false" doesn't cause Page_Load to fire
automatically and trying it out with a simple page this can be confirmed
easily.
However, I have a page with autoeventwireup="false" (that has a masterpage
with autoeventwireup="false" as well) and Page_Load DOES fire in the page.
How can this be ? Other pages using the same Master page does NOT fire
Page_Load, unless I wire up the event manually.
I'm totally confused. Moreover, this specific page fires Page_Load and all
other events TWICE.


Have you explicitly wired the event up? Is this an ASP 1.1 page or 2.0?

Kevin
Aug 25 '06 #4
you where right. on a GridView I had onload=Page_Load by mistake. since it
was a huge page it took me a while to find out why
thanks for your help

"Kevin Jones" wrote:
Carlo Marchesoni wrote:
I read that autoeventwireup="false" doesn't cause Page_Load to fire
automatically and trying it out with a simple page this can be confirmed
easily.
However, I have a page with autoeventwireup="false" (that has a masterpage
with autoeventwireup="false" as well) and Page_Load DOES fire in the page.
How can this be ? Other pages using the same Master page does NOT fire
Page_Load, unless I wire up the event manually.
I'm totally confused. Moreover, this specific page fires Page_Load and all
other events TWICE.


Have you explicitly wired the event up? Is this an ASP 1.1 page or 2.0?

Kevin
Aug 28 '06 #5
you where right. on a GridView I had onload=Page_Load by mistake. since it
was a huge page it took me a while to find out why

"Marina Levit [MVP]" wrote:
If this is the only page with the problem, then clearly something is
different about this page. There must be something else going on there, some
other difference, some other code running that is causing this on the one
particular page, while all other pages are fine.

You should carefully examine all the differences between this page and the
others, as well as remove unecessary pieces of code to really boil it down
to what the problem is.

"Carlo Marchesoni" <Ca*************@discussions.microsoft.comwrote in
message news:C0**********************************@microsof t.com...
I read that autoeventwireup="false" doesn't cause Page_Load to fire
automatically and trying it out with a simple page this can be confirmed
easily.
However, I have a page with autoeventwireup="false" (that has a masterpage
with autoeventwireup="false" as well) and Page_Load DOES fire in the page.
How can this be ? Other pages using the same Master page does NOT fire
Page_Load, unless I wire up the event manually.
I'm totally confused. Moreover, this specific page fires Page_Load and all
other events TWICE.


Aug 28 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Guy Lafleur | last post by:
I have a user control that builds a treeview dynamically in the Page_Load event. Also, I have the AutoEventWireup property set to true (i.e., <%@ Control AutoEventWireup="true" %>). Then, when I...
1
by: Quentin Huo | last post by:
Hi: This morning I found something wrong in my asp.net application: some pages and user controls didn't work well. it seems their Page_load method didnot work. For example if add a statement in...
1
by: prem | last post by:
Hi , Any one please give me the Usage with example for AutoEventWireUp PageDirective. Regards, Prem.
1
by: thomson | last post by:
Hi All, i have written a Web application program, in the page load i have given Response.write=("true") if in the page attribute, the default is AutoEventWireup="false", when i run the program,...
7
by: Danny Tuppeny | last post by:
Hi all, Looks like autoEventWireup defaults to true in 2.0. Kinda silly if you ask me, since the MS site says there's a performance penalty, and I can't imagine it's something used very often! ...
5
by: Juan T. Llibre | last post by:
OK, guys, usually I answer questions instead of asking them, but this thing has me scratching my head. Why is the default for AutoEventWireup different for C# and VB.NET ? In VS 2005, if I...
28
by: Tim_Mac | last post by:
hi, i'm new to .net 2.0, and am just starting to get to grips with the gridview. my page has autoEventWireUp set to true, which i gather is supposed to figure out which handlers to invoke when...
0
by: ABCL | last post by:
Hi All I have UserControl with "AutoEventWireUp="true" Property, and I have drop this User Control on the Master Page MasterPage has: <%@ Master Language="C#" AutoEventWireup="true" ...../> ...
2
by: kellygreer1 | last post by:
So by default the editor only throws in "protected void Page_Load" event. What is the correct way to add in other events. I had in the past copied the events from other pages where I had...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.