template fields for unbound grid

Discussion in 'ASP .Net Web Controls' started by mirin, Oct 7, 2008.

  1. mirin

    mirin Guest

    I have an unbound gridview named grdTemp.

    On the click of a button, I bind grdTemp to a datasource as below:

    grdTemp.DataSource = dsTemp;
    grdTemp.DataBind();

    Works fine and I can see the data.
    The datasource returns records with three text fields and one boolean
    field

    What I need is to be able to display the text values in textboxes and
    the boolean value in a checkbox.
    How can I achieve this?

    I know how to do this on a bound gridview using templatefields. But I
    really need to use an unbound gridview since my actual data will be be
    based on complex conditions.

    Much appreciate any help
     
    mirin, Oct 7, 2008
    #1
    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. =?Utf-8?B?bm93YW5kZXZlcjI5?=

    Unbound fields not getting updated, written to DB VS.Net 2003

    =?Utf-8?B?bm93YW5kZXZlcjI5?=, Apr 6, 2006, in forum: ASP .Net
    Replies:
    2
    Views:
    404
    =?Utf-8?B?bm93YW5kZXZlcjI5?=
    Apr 6, 2006
  2. John

    Adding unbound checkbox to grid

    John, Apr 14, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    619
  3. call_me_anything
    Replies:
    4
    Views:
    473
    Pete Becker
    Sep 30, 2007
  4. Cyril.Liu
    Replies:
    0
    Views:
    459
    Cyril.Liu
    Dec 2, 2008
  5. middletree

    how to copy from fields to other fields

    middletree, Nov 5, 2003, in forum: ASP General
    Replies:
    1
    Views:
    174
    middletree
    Nov 5, 2003
Loading...

Share This Page