Results 1 to 7 of 7

Thread: Grid: Display data in two rows

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jan 2002
    Posts
    320

    Grid: Display data in two rows

    I have a number of columns and a long statement that I need to display on Grid.
    Is it possible to display data of single row from a table into two rows of Grid?
    I would like to display the long statement on the second row. Some of these columns need to be editable.

    Please let me know if .NET grid or Ajax or some Free source exists which I could use.

    I could use VS 2005/VS 2008 for the purpose.

    Thanks

  2. #2
    PowerPoster gep13's Avatar
    Join Date
    Nov 2004
    Location
    The Granite City
    Posts
    21,963

    Re: Grid: Display data in two rows

    Hey,

    To me, it sounds like what you need is a Master/Detail arrangment.

    The first GridView contains some short information about the item in question, enough information so that the user can distinguish on row from another, then when they select that row, they get more detailed information about the row.

    Does that sound right?

    If so, have a look here:

    http://msdn.microsoft.com/en-us/library/aa581796.aspx

    Gary

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Jan 2002
    Posts
    320

    Re: Grid: Display data in two rows

    I need it to be editable. When the user selects the row of the grid, I can use a text box to display the statement and then save, but I was thinking if it was possible to display other columns in one row and the statement in alternate row. Or may be I will have to make some user control.

    Thanks

  4. #4
    PowerPoster gep13's Avatar
    Join Date
    Nov 2004
    Location
    The Granite City
    Posts
    21,963

    Re: Grid: Display data in two rows

    Hey,

    What about the above link suggests that it isn't editable?

    Because it is. You just need to provide the EditItemTemplate for the control to specify which columns the user can edit.

    Have you got an example, perhaps on an existing website of exactly what you are trying to achieve? It is a little difficult to visualize just now.

    Gary

  5. #5

    Thread Starter
    Hyperactive Member
    Join Date
    Jan 2002
    Posts
    320

    Re: Grid: Display data in two rows

    If it is editable that should work. Currently, I'm brainstorming and designing mock-up screens for this project. I will get back with you later in this forum.

    thanks for your help!

  6. #6
    PowerPoster gep13's Avatar
    Join Date
    Nov 2004
    Location
    The Granite City
    Posts
    21,963

    Re: Grid: Display data in two rows

    Hey,

    Ah ok, fair enough.

    Yip, it is definitely editable. post back if you have any more questions.

    Gary

  7. #7
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: Grid: Display data in two rows

    For a single row to be in two rows, you're asking for UI layout flexibility. Use a repeater. A repeater lets you define an ItemTemplate. In this ItemTemplate, you can choose to display your data in any way you want. So you can have two divs, the first with a list of minor data, and the second one on the second line with the lengthy data.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width