Bug Report T105619
Visible to All Users

The first row is selected in master-detail mode (CheckBoxRowSelect mode applied)

created 11 years ago

Below are my two requirements

  1. Master-Detail checkbox sync up
         a) When master check box is checked for row then details rows should be selected and viceversa.
         b) When i uncheck any of the detail row then master row check box should be un checked. Master row check box should be checked only if all the details are checked.
         c) If all the master rows are expanded and if we click on master view header check box then all the master rows and details should be selected.

2)  I have implemented Expand all and Collapse all but it is taking long time to expand all.
for 6000 rows it took around 03 min 28 sec. Is there any way to reduce this time?

Please feel free to modify the attached sample.

Please let me know if you have any other questions.

Comments (1)
Andrew Ser (DevExpress Support) 11 years ago

    Hello,
    In order to better serve and track multiple questions in your inquiry, we have taken the liberty of separating the issues you addressed. Please refer to the Grid - Expanding all detail views takes much time ticket for further correspondence.
    As for the first question, we will process it here.

    Answers approved by DevExpress Support

    created 11 years ago (modified 11 years ago)

    Hello,
    As far as I understand, you are talking about the CheckBoxRowSelect selection mode. To synchronize selection of master and detail views, you need to handle the GridView.SelectionChanged event for both of them and manipulate with row selection manually. I've attached a project illustrating this idea. Please test it and let us know your result.
    Probably, you want to synchronize row selection if you select a master row before expanding this row, but then you expand it. If so, handle the GridView.MasterRowExpanded event and select all rows manually.

      Show previous comments (1)

        Hi,
        Detail first row is selected always when i expand master row. When expand I can call clearslection to unselect all rows but is there a better way to do this?

        Yaroslav (DevExpress Support) 11 years ago

          Hi Anyam,
          I've also noticed that the first row of detail views is selected by default when a master row is expanded. To avoid this shortcoming, use the GridView.ClearSelection method as you already do. There should be no problem with that. In any case, I'll discuss this behavior with our developers. Please bear with me.

          Yaroslav (DevExpress Support) 11 years ago

            Hi Anyam,
            We have discussed this situation, and it appears to be caused by master-detail specifics, because the CheckBoxRowSelection feature was initially designed for a single view only. So, we consider the current behavior correct. Feel free to continue using the GridView.ClearSelection method to overcome this shortcoming.
            I hope this information helps.
            Feel free to contact us at any time.

            Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

            Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.