Get value if invisible

Discussion in 'ASP .Net Datagrid Control' started by ghostwolf, Aug 2, 2006.

  1. ghostwolf

    ghostwolf Guest

    Hi,

    I'm using the asp:gridview control for displaying the data from SQL Server.
    Now, I've found that if the column is invisible
    "<asp:BoundField DataField="some_id" HeaderText="some_id"
    SortExpression="some_id" Visible="false"/>", I cannot get the value from
    that column (just get the null string by "GridView1.Rows[1].Cells[0].Text".



    Thanks.



    Regards,
    ghostwolf, Aug 2, 2006
    #1
    1. Advertising

  2. Web controls with Visible=false don't get sent to client. Hide them rather
    with css style display:none.

    --
    Eliyahu Goldin,
    Software Developer & Consultant
    Microsoft MVP [ASP.NET]

    "ghostwolf" <> wrote in message
    news:ugaj$...
    > Hi,
    >
    > I'm using the asp:gridview control for displaying the data from SQL
    > Server. Now, I've found that if the column is invisible
    > "<asp:BoundField DataField="some_id" HeaderText="some_id"
    > SortExpression="some_id" Visible="false"/>", I cannot get the value from
    > that column (just get the null string by
    > "GridView1.Rows[1].Cells[0].Text".
    >
    >
    >
    > Thanks.
    >
    >
    >
    > Regards,
    >
    >
    >
    >
    Eliyahu Goldin, Aug 2, 2006
    #2
    1. Advertising

  3. ghostwolf

    ghostwolf Guest

    Thanks, how can I add this property to the particular column?

    "Eliyahu Goldin" <> wrote in message
    news:...
    > Web controls with Visible=false don't get sent to client. Hide them rather
    > with css style display:none.
    >
    > --
    > Eliyahu Goldin,
    > Software Developer & Consultant
    > Microsoft MVP [ASP.NET]
    >
    > "ghostwolf" <> wrote in message
    > news:ugaj$...
    >> Hi,
    >>
    >> I'm using the asp:gridview control for displaying the data from SQL
    >> Server. Now, I've found that if the column is invisible
    >> "<asp:BoundField DataField="some_id" HeaderText="some_id"
    >> SortExpression="some_id" Visible="false"/>", I cannot get the value from
    >> that column (just get the null string by
    >> "GridView1.Rows[1].Cells[0].Text".
    >>
    >>
    >>
    >> Thanks.
    >>
    >>
    >>
    >> Regards,
    >>
    >>
    >>
    >>

    >
    >
    ghostwolf, Aug 3, 2006
    #3
  4. ghostwolf

    ghostwolf Guest

    especially in a ASP.NET page.

    "ghostwolf" <> wrote in message
    news:OPHU%...
    > Thanks, how can I add this property to the particular column?
    >
    > "Eliyahu Goldin" <> wrote in message
    > news:...
    >> Web controls with Visible=false don't get sent to client. Hide them
    >> rather with css style display:none.
    >>
    >> --
    >> Eliyahu Goldin,
    >> Software Developer & Consultant
    >> Microsoft MVP [ASP.NET]
    >>
    >> "ghostwolf" <> wrote in message
    >> news:ugaj$...
    >>> Hi,
    >>>
    >>> I'm using the asp:gridview control for displaying the data from SQL
    >>> Server. Now, I've found that if the column is invisible
    >>> "<asp:BoundField DataField="some_id" HeaderText="some_id"
    >>> SortExpression="some_id" Visible="false"/>", I cannot get the value from
    >>> that column (just get the null string by
    >>> "GridView1.Rows[1].Cells[0].Text".
    >>>
    >>>
    >>>
    >>> Thanks.
    >>>
    >>>
    >>>
    >>> Regards,
    >>>
    >>>
    >>>
    >>>

    >>
    >>

    >
    >
    ghostwolf, Aug 3, 2006
    #4
    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. Susan van Houen

    making webcontrols visible/invisible

    Susan van Houen, Jul 13, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    563
    Anatoly
    Jul 13, 2003
  2. =?Utf-8?B?QXNzYW5LaGFuIElzbWFpbA==?=

    How to transfer a value from an Invisible Grid to an visible Grid

    =?Utf-8?B?QXNzYW5LaGFuIElzbWFpbA==?=, Oct 13, 2005, in forum: ASP .Net
    Replies:
    2
    Views:
    467
    =?Utf-8?B?QXNzYW5LaGFuIElzbWFpbA==?=
    Oct 17, 2005
  3. Mariano
    Replies:
    2
    Views:
    475
    =?Utf-8?B?RG91ZyBTYWxvbW9u?=
    Jul 19, 2007
  4. Andy B
    Replies:
    5
    Views:
    591
    Andy B
    May 29, 2008
  5. JLeary

    Getting the value of invisible columns/cells

    JLeary, Jul 29, 2003, in forum: ASP .Net Datagrid Control
    Replies:
    5
    Views:
    119
    Lewis Wang [MSFT]
    Jul 31, 2003
Loading...

Share This Page