accessing formview controls

Discussion in 'ASP .Net' started by Horace Nunley, Aug 28, 2006.

  1. Hi, in my formview "insertItem" template, I have a fileupload control that I
    need to handle when the page is saved.
    I can't get to that control, or any of the controls thru code.

    What gives?

    Thanks
    Horace Nunley, Aug 28, 2006
    #1
    1. Advertising

  2. Horace Nunley

    KJ Guest

    Without seeing any of the code, I would ask the following:

    Do all the controls in the template have an ID attribute?
    If so, you can find them using such code as:

    Button Button1 = (Button)MyFormViewName.FindControl("Button1")

    Please post some of the code so we know what hasn't worked.

    Horace Nunley wrote:
    > Hi, in my formview "insertItem" template, I have a fileupload control that I
    > need to handle when the page is saved.
    > I can't get to that control, or any of the controls thru code.
    >
    > What gives?
    >
    > Thanks
    KJ, Aug 28, 2006
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Nathan Sokalski
    Replies:
    0
    Views:
    387
    Nathan Sokalski
    Jan 11, 2007
  2. justin

    accessing controls in FormView

    justin, Jul 31, 2007, in forum: ASP .Net
    Replies:
    0
    Views:
    455
    justin
    Jul 31, 2007
  3. Nathan Sokalski

    Accessing the controls in the PagerTemplate when using FormView

    Nathan Sokalski, Jan 11, 2007, in forum: ASP .Net Datagrid Control
    Replies:
    0
    Views:
    710
    Nathan Sokalski
    Jan 11, 2007
  4. Arturo Buonanni

    Accessing FormView template controls

    Arturo Buonanni, Apr 4, 2006, in forum: ASP .Net Web Controls
    Replies:
    4
    Views:
    201
    Dabbler
    Apr 14, 2006
  5. Nathan Sokalski

    Accessing the controls in the PagerTemplate when using FormView

    Nathan Sokalski, Jan 11, 2007, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    254
    Nathan Sokalski
    Jan 11, 2007
Loading...

Share This Page