T
tony collier
hello all
i have created a simple page :
<%@ Page language="c#" %>
<%@ Import Namespace="System" %>
<script runat="server">
void Page_Load(Object sender, EventArgs e) {
....
string name="tony";
.....
}
</script>
....
<body>
....
<% if (name!=null){Response.Write("<table><tr><td>tony</td></tr>
</table>");} %>
....
</body>
</html>
when i try to compile this i get an error stating that there is no
defintion for 'name'. Why can't my inline code access a variable in the
page load script? I fear i have seriously misunderstood something......
i have created a simple page :
<%@ Page language="c#" %>
<%@ Import Namespace="System" %>
<script runat="server">
void Page_Load(Object sender, EventArgs e) {
....
string name="tony";
.....
}
</script>
....
<body>
....
<% if (name!=null){Response.Write("<table><tr><td>tony</td></tr>
</table>");} %>
....
</body>
</html>
when i try to compile this i get an error stating that there is no
defintion for 'name'. Why can't my inline code access a variable in the
page load script? I fear i have seriously misunderstood something......