Multiple selection in GridDataControl
Does GrdiDataControl support multiple row selection? From the properties in the code behind, I only see the "SelectedItem" but there are no "SelectedItems", I wonder if they have something similar to that.
One more thing, is it possible to resize row height after the application is run? I have tried to set the "AllowResizeRows" to true, however, I still cannot resize the row height, but I could resize the column width though...
Thank you very much.
One more thing, is it possible to resize row height after the application is run? I have tried to set the "AllowResizeRows" to true, however, I still cannot resize the row height, but I could resize the column width though...
Thank you very much.
SIGN IN To post a reply.
3 Replies
KA
Kamalakannan A
Syncfusion Team
August 11, 2010 07:22 PM UTC
Hi Jimmy,
Thanks for using syncfusion products. You can set the ListboxSelectionMode option to MultiExtent which allows to multiple select in the grid as follows.
[Code] [C#]
void dataGrid_Loaded(object sender, RoutedEventArgs e)
{
this.dataGrid.ListBoxSelectionMode = GridSelectionMode.MultiExtended;
}
[Code] [Xaml]
ShowAddNewRow="False"
ShowFilters="False"
AutoPopulateColumns="False"
AutoPopulateRelations="False"
VisualStyle="Office14Silver"
ListBoxSelectionMode="MultiExtended">
To Resize the row height in UI you need to set the showrowHeader Property to true as follows. this will allows you to resize the row height.
[Code] [Xaml]
ShowAddNewRow="False"
ShowFilters="False"
AutoPopulateColumns="False"
AutoPopulateRelations="False"
VisualStyle="Office14Silver"
ShowRowHeader="True"
ListBoxSelectionMode="MultiExtended">
Let us know if you need any more information.
Thanks
Kamalakannan
Thanks for using syncfusion products. You can set the ListboxSelectionMode option to MultiExtent which allows to multiple select in the grid as follows.
[Code] [C#]
void dataGrid_Loaded(object sender, RoutedEventArgs e)
{
this.dataGrid.ListBoxSelectionMode = GridSelectionMode.MultiExtended;
}
[Code] [Xaml]
ShowFilters="False"
AutoPopulateColumns="False"
AutoPopulateRelations="False"
VisualStyle="Office14Silver"
ListBoxSelectionMode="MultiExtended">
To Resize the row height in UI you need to set the showrowHeader Property to true as follows. this will allows you to resize the row height.
[Code] [Xaml]
ShowFilters="False"
AutoPopulateColumns="False"
AutoPopulateRelations="False"
VisualStyle="Office14Silver"
ShowRowHeader="True"
ListBoxSelectionMode="MultiExtended">
Let us know if you need any more information.
Thanks
Kamalakannan
AD
Administrator
Syncfusion Team
February 11, 2011 03:06 PM UTC
What property or event (or something else?) do you use to get items that are selected?
Thanks
Thanks
MK
Mayavel K
Syncfusion Team
February 22, 2011 10:41 AM UTC
Hi Jimmy,
You can use the selection changed event and the property SelectedItems property that return the selected Items collection.
Following code snippets illustrates this.
[Code] [C#}
dataGrid.Model.SelectionChanged += new Syncfusion.Windows.Controls.Grid.GridSelectionChangedEventHandler(Model_SelectionChanged);
void Model_SelectionChanged(object sender, Syncfusion.Windows.Controls.Grid.GridSelectionChangedEventArgs e)
{
var order = dataGrid.SelectedItems;
}
Regards,
Mayavel K
You can use the selection changed event and the property SelectedItems property that return the selected Items collection.
Following code snippets illustrates this.
[Code] [C#}
dataGrid.Model.SelectionChanged += new Syncfusion.Windows.Controls.Grid.GridSelectionChangedEventHandler(Model_SelectionChanged);
void Model_SelectionChanged(object sender, Syncfusion.Windows.Controls.Grid.GridSelectionChangedEventArgs e)
{
var order = dataGrid.SelectedItems;
}
Regards,
Mayavel K
SIGN IN To post a reply.
- 3 Replies
- 4 Participants
-
JJ Jimmy Ji
- Aug 2, 2010 01:29 PM UTC
- Feb 22, 2011 10:41 AM UTC