GridVIew columns (hidden)

Discussion in 'ASP .Net' started by MP, Feb 15, 2007.

  1. MP

    MP Guest

    Hi all,

    who knows how to use hidden columns from GridView in Update Command from
    attached to it SqlDataSource? For example: I have hidden column UserId and
    for given case I want to use it as @UserId variable in update command. When
    this column is redaonly then this variable has null values. So is there any
    way to it with oryginal value?

    MP
    MP, Feb 15, 2007
    #1
    1. Advertising

  2. When you hide comtrols with Visible=false, they don't get rendered to the
    client and don't come back in postbacks. To get the value on postbacks, hide
    with css rule display:none.

    --
    Eliyahu Goldin,
    Software Developer & Consultant
    Microsoft MVP [ASP.NET]
    http://msmvps.com/blogs/egoldin
    http://usableasp.net


    "MP" <> wrote in message
    news:er146g$rmr$...
    > Hi all,
    >
    > who knows how to use hidden columns from GridView in Update Command from
    > attached to it SqlDataSource? For example: I have hidden column UserId and
    > for given case I want to use it as @UserId variable in update command.
    > When this column is redaonly then this variable has null values. So is
    > there any way to it with oryginal value?
    >
    > MP
    Eliyahu Goldin, Feb 15, 2007
    #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. Mark Rae

    GridView controls and hidden columns

    Mark Rae, May 14, 2006, in forum: ASP .Net
    Replies:
    2
    Views:
    2,389
    Mark Rae
    May 14, 2006
  2. Jacksm
    Replies:
    2
    Views:
    848
    Paul Chalekian
    Nov 21, 2006
  3. Steven Nagy

    GridView ObjectDataSource hidden columns

    Steven Nagy, Feb 7, 2007, in forum: ASP .Net
    Replies:
    2
    Views:
    625
    Steven Nagy
    Feb 8, 2007
  4. Rick
    Replies:
    3
    Views:
    8,150
    Alexey Smirnov
    Apr 13, 2010
  5. Vinki

    template columns and bound columns in gridview

    Vinki, Apr 25, 2007, in forum: ASP .Net Web Controls
    Replies:
    2
    Views:
    858
    Vinki
    Apr 25, 2007
Loading...

Share This Page