Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. ASP.net web controls

ASP.net web controls

Scheduled Pinned Locked Moved ASP.NET
helpcsharpasp-net
5 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    mahichandu
    wrote on last edited by
    #1

    Hi .. am getting error like this..can anyone help..in my pageload there is no errors ..only 1 error from aspx page Error:does not contain a definition for 'ddlYear_SelcetedIndexChanged'

    <%@ Register TagPrefix="users" TagName="YearDropdownList" Src="~/UserControls/YearListBox1.ascx" %>

    .aspx

    .aspx.cs

    pageload:

    protected void dd1Year_SelectedIndexChanged(Object sender, EventArgs e)
    {
    //callling string from my user control
    sYear = ddlYear.SelectedValue.Trim();
    }

    C D 2 Replies Last reply
    0
    • M mahichandu

      Hi .. am getting error like this..can anyone help..in my pageload there is no errors ..only 1 error from aspx page Error:does not contain a definition for 'ddlYear_SelcetedIndexChanged'

      <%@ Register TagPrefix="users" TagName="YearDropdownList" Src="~/UserControls/YearListBox1.ascx" %>

      .aspx

      .aspx.cs

      pageload:

      protected void dd1Year_SelectedIndexChanged(Object sender, EventArgs e)
      {
      //callling string from my user control
      sYear = ddlYear.SelectedValue.Trim();
      }

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      Why do you show us the 'register' part ? Is the event inside the control's .cs file ?

      Christian Graus Driven to the arms of OSX by Vista. "! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums. I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp

      M 1 Reply Last reply
      0
      • C Christian Graus

        Why do you show us the 'register' part ? Is the event inside the control's .cs file ?

        Christian Graus Driven to the arms of OSX by Vista. "! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums. I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp

        M Offline
        M Offline
        mahichandu
        wrote on last edited by
        #3

        You mean Usercontrol .cs file..Yeah i wrote my method in usercontrol..i am calling stored procedure in usercontrol to display list of years..

        C 1 Reply Last reply
        0
        • M mahichandu

          You mean Usercontrol .cs file..Yeah i wrote my method in usercontrol..i am calling stored procedure in usercontrol to display list of years..

          C Offline
          C Offline
          Christian Graus
          wrote on last edited by
          #4

          I notice you use Object instead of object, but I'm not sure that should matter. Other than that, I see no reason, if the control is in usercontrol.aspx and the event is in usercontrol.aspx.cs, for there to be an issue.

          Christian Graus Driven to the arms of OSX by Vista. "! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums. I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp

          1 Reply Last reply
          0
          • M mahichandu

            Hi .. am getting error like this..can anyone help..in my pageload there is no errors ..only 1 error from aspx page Error:does not contain a definition for 'ddlYear_SelcetedIndexChanged'

            <%@ Register TagPrefix="users" TagName="YearDropdownList" Src="~/UserControls/YearListBox1.ascx" %>

            .aspx

            .aspx.cs

            pageload:

            protected void dd1Year_SelectedIndexChanged(Object sender, EventArgs e)
            {
            //callling string from my user control
            sYear = ddlYear.SelectedValue.Trim();
            }

            D Offline
            D Offline
            DoctorMick
            wrote on last edited by
            #5

            Have you copy and pasted the code snippets and the error message? I ask because the method name in the error message doesn't match those in the code.

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups