in

C1 Community

ComponentOne Community is a free source for developers and help authors to collaborate and communicate.

Get TrueDBGrid Group Colomn Text Please

Last post 05-30-2008 1:01 AM by anilsoni85. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 04-01-2008 11:49 AM

    Get TrueDBGrid Group Colomn Text Please

               Hi everyone.  I have a huge problem about TrueDbGrid.

      In my win. application  there is a TrueDbGrid which have 2 Grouped Columns. It works fine. But

    when I select first groupe column , I want to know that what is first groupe column  TEXT  or  i can select second one.

     

    - Group x1        ==> this row can select and i want ==> x1
       - Group x2     ==> this row can select and i want ==> x2
           Row 1
           Row 2
           Row 3
          
    -Group x3       ==> this row can select and i want ==> x3
      - Group x2    ==> this row can select and i want ==> x4
           Row 5
           Row 6
           Row 7
         

       Thank you.

     

  • 04-03-2008 6:20 AM In reply to

    Re: Get TrueDBGrid Group Colomn Text Please

    Hi

     

    C1TrueDBGrid1.GroupedColumns(0).CellText(0) will get you X1

     

    C1TrueDBGrid1.GroupedColumns(1).CellText(0) will get you X2

     

    Reagrds

    Dave

    <EyupBaba> wrote in message news:203403@10.0.1.98...

               Hi everyone.  I have a huge problem about TrueDbGrid.

      In my win. application  there is a TrueDbGrid which have 2 Grouped Columns. It works fine. But

    when I select first groupe column , I want to know that what is first groupe column  TEXT  or  i can select second one.

     

    - Group x1        ==> this row can select and i want ==> x1
       - Group x2     ==> this row can select and i want ==> x2
           Row 1
           Row 2
           Row 3
          
    -Group x3       ==> this row can select and i want ==> x3
      - Group x2    ==> this row can select and i want ==> x4
           Row 5
           Row 6
           Row 7
         

       Thank you.

     



    http://helpcentral.componentone.com/cs/forums/p/74807/203403.aspx#203403

  • 05-30-2008 1:01 AM In reply to

    Re: Get TrueDBGrid Group Colomn Text Please

    i think the following code will help you.

    GroupRow gr= (GroupRow)dataGrid.SelectedRow[0];

    Console.Write("Your Required Text is here: " + gr.GroupText);

    (Please find the exact method  or property name from the intellesense. This code is just for an example that you can get the cell Text from GroupRow object by converting the selected row  into an GroupRow (BaseGrid.ViewRow.GroupRow is the namespace i think. Just have a look over documentation for more info about GroupRow)

     

Page 1 of 1 (3 items)
Contact ComponentOne: 1.800.858.2739 ©1987-2008 ComponentOne LLC All Rights Reserved.