text box in FooterTemplate

Discussion in 'ASP .Net Datagrid Control' started by Salam, May 18, 2006.

  1. Salam

    Salam Guest

    Hi,

    I have a DG not visible on a web page. Clicking a button will display the DG
    which has a TemplateColumn in which there is a FooterTemplate which contains
    text box in its footer as follows.

    I am trying to set the value of the text box dynamically while the DG being
    rendered withouit success. When I add the text attribute in the footer tag
    directly as follows


    <FooterTemplate>

    <asp:TextBox id="txtBox_Range_ID" text="dddd" runat="server"></asp:TextBox>

    </FooterTemplate>


    The value "dddd" is displayed correctly when the page is rendered. So if
    possible what event or object I should use to be able to do this
    programmatically and in which event.

    Also, what is the best way to access (set/get valus) in a footer content

    I tried different tips (CType(e.Item.Cells(1).FindControl...,
    myDG.items(0).find...) without success.

    Thanks in advance
     
    Salam, May 18, 2006
    #1
    1. Advertisements

  2. if you were workin' with a GridView... I would help you and sayed to use the
    RowCreated event, inseide that you use an if clause checking if the row is a
    footer row, and if it was, then you could apply what you need to it...

    but I do not know (and really dont wanna know) how to do it in a dataGrid
    :)

    GridView Rules :p

    --

    Bruno Alexandre
    (a Portuguese in KĂžbenhanv, Danmark)


    "Salam" <> escreveu na mensagem
    news:...
    > Hi,
    >
    > I have a DG not visible on a web page. Clicking a button will display the
    > DG which has a TemplateColumn in which there is a FooterTemplate which
    > contains text box in its footer as follows.
    >
    > I am trying to set the value of the text box dynamically while the DG
    > being rendered withouit success. When I add the text attribute in the
    > footer tag directly as follows
    >
    >
    > <FooterTemplate>
    >
    > <asp:TextBox id="txtBox_Range_ID" text="dddd"
    > runat="server"></asp:TextBox>
    >
    > </FooterTemplate>
    >
    >
    > The value "dddd" is displayed correctly when the page is rendered. So if
    > possible what event or object I should use to be able to do this
    > programmatically and in which event.
    >
    > Also, what is the best way to access (set/get valus) in a footer content
    >
    > I tried different tips (CType(e.Item.Cells(1).FindControl...,
    > myDG.items(0).find...) without success.
    >
    > Thanks in advance
    >
    >
     
    Bruno Alexandre, May 18, 2006
    #2
    1. Advertisements

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. Jorge Loaiza Arango

    Access to controls in <FooterTemplate>

    Jorge Loaiza Arango, Dec 21, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    710
    Jose Suero
    Dec 21, 2003
  2. =?Utf-8?B?bWFoc2E=?=

    how can I access to controls in footertemplate

    =?Utf-8?B?bWFoc2E=?=, Jul 9, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    384
    =?Utf-8?B?bWFoc2E=?=
    Jul 9, 2004
  3. Vishal

    Footertemplate is called twice?

    Vishal, Jan 12, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    383
    Scott Allen
    Jan 12, 2005
  4. Arthur Dent

    Repeater footertemplate shows on TOP

    Arthur Dent, Sep 28, 2005, in forum: ASP .Net
    Replies:
    3
    Views:
    906
    Eliyahu Goldin
    Sep 28, 2005
  5. Gnarlodious
    Replies:
    4
    Views:
    17,857
    elizas
    May 5, 2010
Loading...

Share This Page