Current filter:
                                You should refresh the page.
                                Support Center
                                0

                                Hello all,

                                I have a need to construct a custom repositoryItemCheckedComboBoxEdit, which will host for each item a checkbox, and a textbox next to it. Those items need to be constructed dynamically based on entries made into another repositoryItemCheckedComboBoxEdit on the same row in the grid.
                                Attached to this message is a sample project. In it you will find a grid hosting a number of columns. Among them you will find two columns, CheckBoxes and DynamicCheckboxEditor. For DynamicCheckboxEditor I need the following :

                                When the user selects that cell, I need to add checkboxes to it that are basically all checked entries in the CheckBoxes cell on the same row.

                                Thanks

                                Attachment.txt
                                0

                                Hello Ahmad,

                                Thanks for your question. I suggest that you handle the GridView.ShownEditor event. Within this event handler, you can obtain the currently displayed clone of the column editor, and filter its items. Here is some sample code:

                                	
                                [C#]
                                private void gridView_ShownEditor(object sender, EventArgs e) { GridView view = (GridView)sender; if (view.FocusedColumn != colDynamicCheckboxEditor) return; CheckedComboBoxEdit editor = (CheckedComboBoxEdit)view.ActiveEditor; string[] selectedValues = gridView.GetRowCellValue(gridView.FocusedRowHandle, colAllCheckBoxes).ToString().Split(repositoryItemCheckedComboBoxEdit1.SeparatorChar); string[] selectedDescriptions = gridView.GetRowCellDisplayText(gridView.FocusedRowHandle, colAllCheckBoxes).Split(repositoryItemCheckedComboBoxEdit1.SeparatorChar); editor.Properties.Items.Clear(); for (int i = 0; i < selectedValues.Length; i++) editor.Properties.Items.Add(new RadioGroupItem(selectedValues[i], selectedDescriptions[i])); }

                                The modified project is attached.

                                Thanks,
                                Uriah.

                                GridView.zip

                                To start a chat you should create a support ticket


                                If you need additional product information, write to us at info@devexpress.com or call us at +1 (818) 844-3383

                                FOLLOW US

                                DevExpress engineers feature-complete Presentation Controls, IDE Productivity Tools, Business Application Frameworks, and Reporting Systems for Visual Studio, along with high-performance HTML JS Mobile Frameworks for developers targeting iOS, Android and Windows Phone. Whether using WPF, Silverlight, ASP.NET, WinForms, HTML5 or Windows 8, DevExpress tools help you build and deliver your best in the shortest time possible.

                                Copyright © 1998-2014 Developer Express Inc.
                                All trademarks or registered trademarks are property of their respective owners