I am using a RadGridView to display information about people.
The last column is for edit/delete buttons.
Whenever I set the last column's width to "*" (to fill the rest of the space), a horizontal scroll bar appears.
If I have 1 column in my grid, then the last column's width properly fills the remaining space and no horizontal scroll bar appears; however, the more columns that I add to the grid, the more you have to scroll to see the edit buttons (the worse the horizontal scroll bar becomes).
This is the markup for my GridView:
Thanks, in advanced, for your help!
The last column is for edit/delete buttons.
Whenever I set the last column's width to "*" (to fill the rest of the space), a horizontal scroll bar appears.
If I have 1 column in my grid, then the last column's width properly fills the remaining space and no horizontal scroll bar appears; however, the more columns that I add to the grid, the more you have to scroll to see the edit buttons (the worse the horizontal scroll bar becomes).
This is the markup for my GridView:
<
telerik:RadGridView
Name
=
"PeopleGrid"
Width
=
"{Binding ElementName=theRootElement, Path=ActualWidth}"
ItemsSource
=
"{Binding Source={StaticResource people}, Path=People}"
IsReadOnly
=
"True"
EditTriggers
=
"None"
>
<
telerik:RadGridView.Columns
>
<
telerik:GridViewToggleRowDetailsColumn
ExpandMode
=
"Single"
/>
<
telerik:GridViewDataColumn
Header
=
"First Name"
DataMemberBinding
=
"{Binding FirstName}"
/>
<
telerik:GridViewDataColumn
Header
=
"Last Name"
DataMemberBinding
=
"{Binding LastName}"
/>
<
telerik:GridViewDataColumn
Header
=
"Age"
DataMemberBinding
=
"{Binding Age}"
/>
<
telerik:GridViewDataColumn
Header
=
"Marital Status"
DataMemberBinding
=
"{Binding MaritalStatus}"
/>
<
telerik:GridViewDataColumn
Width
=
"*"
>
<
telerik:GridViewDataColumn.CellStyle
>
<
Style
TargetType
=
"telerik:GridViewCell"
>
<
Setter
Property
=
"Template"
>
<
Setter.Value
>
<
ControlTemplate
>
<
StackPanel
Orientation
=
"Horizontal"
HorizontalAlignment
=
"Right"
>
<
Button
x:Name
=
"btn_EditPerson"
ToolTip
=
"Edit"
>
Edit
</
Button
>
<
Button
ToolTip
=
"Delete"
Command
=
"{Binding Source={StaticResource people}, Path=DeletePerson}"
CommandParameter
=
"{Binding .}"
>
Delete
</
Button
>
</
StackPanel
>
</
ControlTemplate
>
</
Setter.Value
>
</
Setter
>
</
Style
>
</
telerik:GridViewDataColumn.CellStyle
>
</
telerik:GridViewDataColumn
>
</
telerik:RadGridView.Columns
>
<
telerik:RadGridView.RowDetailsTemplate
>
<
DataTemplate
>
<!-- Additional Controls to Display Additional Info...has no affect on problem if I comment this part out -->
</
DataTemplate
>
</
telerik:RadGridView.RowDetailsTemplate
>
</
telerik:RadGridView
>
Thanks, in advanced, for your help!