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 Ajax - Problem referencing object to a ModalPopupExtender within a gridview row.

Asp.Net Ajax - Problem referencing object to a ModalPopupExtender within a gridview row.

Scheduled Pinned Locked Moved ASP.NET
helpcsharphtmlasp-netcom
1 Posts 1 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.
  • L Offline
    L Offline
    Larantz
    wrote on last edited by
    #1

    Hi. I couldn't find a forum for Ajax so I guess it falls under asp.net. :) I'm working on a timesheet control that consists of a gridview with a column for each day. The column consists of a textbox for working hour input and an imagebutton for entering a comment for the given day. I've been trying to add a ModalPopupExtender to the item template and to set the imagebutton ClientID to the extenders TargetControlID property. This is for displaying the input controls for the comment. Setting the imagebutton id to the TargetControlID property in the markup doesn't work as the imagebuttons id is dynamically created for each row when the gridview performs the databinding. I've been experimenting with the gridviews OnPreRender method where I iterate over the rows, locate the imagebutton and extender for the given row, and set the TargetControlID. I get a asp.net error stating: The TargetControlID of 'commentModalPopupExtender' is not valid. A control with ID 'ctl00_Main_timesheetControl_gvTimeSheet_ctl02_imBtnMondayComment' could not be found. As far as I know, that id looks exactly right according to what I've seen when I look at the source of the page. Anyone who've encountered (and solved) this problem? Best regards! Larantz

    for those about to code, we salute youhttp://www.itverket.noPlease refer to the Forum Guidelines for appropriate posting.

    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