My test.aspx is at C:InetpubwwwrootTest<BR>My CodeBehind.cs is at C:InetpubwwwrootTest<BR><BR>I pre-compile the CodeBehind.cs to CodeBehind.dll and <BR>put it into C:InetpubwwwrootTestin<BR><BR>In my test.aspx, I change the:<BR><BR><%@ Page language="c#" src=http://aspmessageboard.com/archive/index.php/"CodeBehind.cs" Inherits="ASPPlus.CodeBehind"" %><BR><BR><BR>to <BR><BR><%@ Page language="c#" Inherits="ASPPlus.CodeBehind" %><BR><BR>Then, the page gives me an error.<BR><BR><BR>It said:<BR>Parser Error Message: 'ASPPlus.CodeBehind' is not a valid type.<BR><BR><BR>My question is: <BR>How can I just use the DLL, NOT the CodeBehind.cs ??<BR><BR><BR>I am using ASP.NET, NotePad - I have no money to buy VS
<BR><BR>Thank you for your help!!<BR><BR><BR><BR>PS:<BR><BR>test.apsx<BR><BR><%@ Page language="c#" Inherits="ASPPlus.CodeBehind" %><BR><HTML><BR><HEAD><title>test</title><BR></HEAD><BR><BR><body style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana,Arial,sans-serif"><BR><BR><form action="CodeBehind.aspx" method="post" runat="server"><BR><p align=center>Demonstration of Code Behind File</p><BR><p align=center><BR> <asp:Label id="Message" runat="server"></asp:Label><BR></p><BR><BR><p><BR><table align="center" id="tblSignIn" cellpadding="1" cellspacing="1" bgcolor="black" runat="server"><BR><tr><BR> <td><BR> <table align="center" cellpadding="1" cellspacing="1" bgcolor="lightskyblue" runat="server"><BR> <tr><BR> <td colspan="2" align="middle"><h5>Sign-In Form</h5></td><BR> </tr><BR> <tr><BR> <td align=right valign=top>Login:</td><BR> <td align=left><BR> <asp:TextBox id=txtLogin Width=200 Runat=server></asp:TextBox><BR></br><BR> <asp:RequiredFieldValidator ID="RFVLogin" ControlToValidate="txtLogin" Display="Static" Font-Name="verdana,arial,sans-serif" Font-Size="9pt" ErrorMessage="You must enter a Login." runat=server></asp:RequiredFieldValidator><BR> </td><BR> </tr><BR> <tr><BR> <td align=right valign=top>Password:</td><BR> <td align=left><BR> <asp:TextBox id=txtPassword Width=200 Runat=server TextMode="Password"></asp:TextBox><BR></br><BR> <asp:RequiredFieldValidator ControlToValidate="txtPassword" Display="Static" Font-Name="verdana,arial,sans-serif" Font-Size="9pt" ErrorMessage="You must enter a password." runat=server ID="RFVPassword"> </asp:RequiredFieldValidator><BR> </td><BR> </tr><BR> <tr><BR> <td colspan=2 align=middle><asp:Button id=btnSignIn Runat="server" Text="Sign In" onClick="btnSignIn_Click"></asp:Button></td><BR> </tr><BR> </table> <BR> </td><BR></tr><BR></table><BR></p><BR><BR></form><BR></body><BR></html><BR><BR><BR>CodeBehind.cs<BR><BR>namespace ASPPlus<BR>{<BR>using System;<BR>using System.Web;<BR>using System.Web.UI;<BR>using System.Web.UI.WebControls;<BR>using System.Web.UI.HtmlControls;<BR><BR>public class CodeBehind : System.Web.UI.Page<BR>{<BR> public System.Web.UI.WebControls.Label Message;<BR> public System.Web.UI.HtmlControls.HtmlTable tblSignIn;<BR> public System.Web.UI.WebControls.TextBox txtLogin;<BR> public System.Web.UI.WebControls.RequiredFieldValidator RFVLogin;<BR> public System.Web.UI.WebControls.TextBox txtPassword;<BR> public System.Web.UI.WebControls.RequiredFieldValidator RFVPassword;<BR> public System.Web.UI.WebControls.Button btnSignIn;<BR> <BR> protected void Page_Load(object sender, EventArgs e)<BR> {<BR> if (!IsPostBack)<BR> {<BR> Message.Text = "Enter Login and Password";<BR> }<BR> }<BR><BR> protected void btnSignIn_Click(Object obj, EventArgs e)<BR> {<BR> if(Page.IsValid)<BR> {<BR> if( txtLogin.Text == "o" && txtPassword.Text == "ok" )<BR> {<BR> Message.Text = "Congratulations, " + txtLogin.Text + "!!! You have successfully signed in.";<BR> tblSignIn.Visible = false; <BR> }<BR> else<BR> {<BR> Message.Text = "Invalid User Name and Password. Try Again.";<BR> }<BR> }<BR><BR> }<BR>}<BR>}<BR>try putting the compiled .dll into the root web folder. in this case it'd probably be C:Inetpubwwwrootin. unless the directory Test is a virtual directory, the compiled dlls need to go directly under the application's root directory.Dear n1ck,<BR><BR>Thank you so much!!<BR><BR>I am crazy for it for 2 days!!<BR><BR><BR><BR>
