You ve defined one page_load event in aspx page and same
page_load event in code behind how will prog run?
Answer Posted / sudhir sheoran
Page load of aspx will be given preference
e.g:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default"%>
<script runat="server">
protected void Page_Load(object sender, EventArgs e)
{
Response.Write("Page");
}
</script>
<head runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>
</div>
</form>
</body>
</html>
And in Code Behind:
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
Response.Write("Behind");
}
}
SO Page will be shown as output not behind
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
How you will improve web application performance?
What is caching? Explain.
What is odata in web api?
We Only Know The Total Number Of Feet In The Farmyard. Write A Program that will compute the total number of rabbits and chickens in the farmyard. Assume number of feet in the farmyard are 40. how many rabbits and chickens are?
Explain program to call the js function when the change is being made in the dropdown list made in asp.net mvc? : asp.net mvc
Are there any resources for drop-in replacements for the default css that comes with the ASP.NET Website template?
How you can access the values from the Repeater control in ASP.NET?
Define dll hell?
How does http session work?
What is the difference between an htmlinputcheckbox control and an htmlinputradiobutton control?
Explain how is a property designated as read-only?
Can you clarified A Web service can only be written in .NET or not?
How can we prevent browser from caching an aspx page?
What is webresource axd?
What I need to create and run an asp.net application?