Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

IIS does not recognize asp.net code

Status
Not open for further replies.

bonzep

Programmer
Dec 5, 2007
2
US
Hello,

I'm new to asp.net.

I have IIS 5.0 running on XP. The dotnet framework 1.1 is installed.

I've created a very simple ASPX page:

<html>
<body bgcolor="yellow">
<center>
<h2>Hello W3Schoolsxx!</h2>
<p><%Response.Write(now())%></p>
</center>
</body>
</html>


All the html code runs but not the asp code.

If I change the extension to asp, the asp code runs.

Thanks for your time
 
You are using a classic ASP way of styling. ASP.NET is best used with the code behind file. In there you could test your page like this:
Code:
    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Resonse.write(Now())
End Sub

Visual Studio will create the event handler syntax for you.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top