Wrox Programmer Forums
Go Back   Wrox Programmer Forums > .NET > Other .NET > General .NET
|
General .NET For general discussion of MICROSOFT .NET topics that don't fall within any of the other .NET forum subcategories or .NET language forums.  If your question is specific to a language (C# or Visual Basic) or type of application (Windows Forms or ASP.Net) try an applicable forum category. ** PLEASE BE SPECIFIC WITH YOUR QUESTION ** When posting here, provide details regarding the Microsoft .NET language you are using and/or what type of application (Windows/Web Forms, etc) you are working in, if applicable to the question. This will help others answer the question without having to ask.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the General .NET section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 6th, 2005, 06:53 PM
Registered User
 
Join Date: Jul 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to theycallmetish
Default OnCheckedChanged trouble with codebehind method

hey. i'll get right into it. i've got a codebehind page and my presentation page. i've got this code for my checkbox, which in theory is supposed to (when checked) take the first and last name of the filled out form and put the same text into two other textboxs further down the page. here's the code
Code:
public void payableBox_CheckedChanged(Object sender, EventArgs e)
 {
  if (payableBox.Checked)
   {
     payfname.Text = fn.Text;
     paylname.Text = ln.Text;
   }
   else
   {
     payfname.Text="";
     paylname.Text="";
   }
}
and

Code:
<asp:checkbox id="payableBox" Text="Same Address as above" OnCheckedChanged="payableBox_CheckedChanged" checked="false" AutoPostBack="true" runat="server"></asp:checkbox>
i keep on getting this compile error

 CS0117: 'ASP.signup_aspx' does not contain a definition for 'payableBox_CheckedChanged'

can anyone help?

 
Old July 9th, 2005, 01:33 PM
planoie's Avatar
Friend of Wrox
 
Join Date: Aug 2003
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts
Default

This smells like a problem with either the ASPX file's class inheritance or a compiling issue. Everything else looks ok from my view.

-Peter





Similar Threads
Thread Thread Starter Forum Replies Last Post
Codebehind not working angshujit ASP.NET 1.0 and 1.1 Basics 1 September 21st, 2007 07:32 AM
JSP Codebehind buddhudev Pro JSP 0 October 1st, 2005 02:33 PM
Trouble with date method... budman Javascript 2 May 25th, 2004 10:04 AM
Setting oncheckedchanged event in code behind file katsarosj VS.NET 2002/2003 4 May 12th, 2004 12:22 PM
Ch15 CodeBehind mahir BOOK: Beginning ASP.NET 1.0 2 May 8th, 2004 01:58 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.