If one follows the guide from the online documentation to create custom summary cell element he will no be able to use it in a custom column: http://www.telerik.com/help/winforms/gridview-cells-custom-cells.html The issue is that the GetCellType method of the column is never called for summary rows.
To reproduce, use the following localization provider and set a fitler to a boolean column in RadGridView, via the Custom filtering dialog.
class MyRadGridLocalizationProvider : RadGridLocalizationProvider
{
public const string CustomTrue = "CustomTRUE";
public const string CustomFalse = "CustomFALSE";
public override string GetLocalizedString(string id)
{
if (id == "CustomFilterDialogTrue")
{
return CustomTrue;
}
else if (id == "CustomFilterDialogFalse")
{
return CustomFalse;
}
else
{
return base.GetLocalizedString(id);
}
}
}
Workaround - create custom type converter as follows:
public class MyBooleanConverter : BooleanConverter
{
public override object ConvertFrom(ITypeDescriptorContext context, System.Globalization.CultureInfo culture, object value)
{
if (value is string)
{
string text = Convert.ToString(value);
if (text == MyRadGridLocalizationProvider.CustomTrue)
{
return true;
}
else if (text == MyRadGridLocalizationProvider.CustomFalse)
{
return false;
}
}
return base.ConvertFrom(context, culture, value);
}
}
and apply it to the check box column:
radGridView1.Columns["BoolColumn"].DataTypeConverter = new MyBooleanConverter();
Steps to reproduce: 1. Add a grid to a form and add two expression columns 2. Enable Excel-like filtering 3. Add data 4. Run the project and filter on both expression columns You will see an exception.
If you end edit of sorted decimal column by pressing ENTER key, the StackOverflowException is thrown.
1. Create a new project with RadGridView and bind it. 2. Add a GridViewComboBoxColumn and bind it to a generic list that contains KeyValuePair instancess. Set the key to be an enum and set the ValueMember property of the column to point to this field. 3. Run the project and try to filter by this column.
To reproduce: - Set BeginEditMod to BeginEditProgrammatically - Check/uncheck a check box cell and you will be able to edit the rest of the cells
Currently csv files are exported with UTF-8 encoding. There should be an option allowing users to change it.
Steps to reproduce: 1. Add a RadGridView to a form 2. Add several columns and set their MinWidth to 0 3. Set the grid AutoSizeColumnsMode property to Fill 4. Run the project and you will see that you cannot resize the columns. WORKAROUND: Set the MinWidth property to a value greater than 0
To reproduce: GridViewMaskBoxColumn maskBoxColumn = new GridViewMaskBoxColumn(); maskBoxColumn.Name = "MaskEditBoxColumn"; maskBoxColumn.HeaderText = "MaskEditBoxColumn"; maskBoxColumn.MaxLength = 5; maskBoxColumn.MaskType = MaskType.Numeric; maskBoxColumn.Mask = "C"; maskBoxColumn.FormatString = "{0:C}"; radGridView1.MasterTemplate.Columns.Add(maskBoxColumn); WORKAROUND: void radGridView1_CellEditorInitialized(object sender, GridViewCellEventArgs e) { GridSpinEditor editor = e.ActiveEditor as GridSpinEditor; if (editor != null) { GridSpinEditorElement element = (GridSpinEditorElement)editor.EditorElement; element.TextChanging += element_TextChanging; } } void element_TextChanging(object sender, TextChangingEventArgs e) { e.Cancel = e.NewValue.Length > 5; }
Comment : Removed the MaxLength property from GridViewMaskBoxColumn. You should use the Mask property and set an appropriate mask value. For example the #### mask allows entering only 4 digits.
The RadGridView throws unhandled exception, when you try to close the custom filtering form twice for invalid filter descriptor.
1. Create a new project with RadGridView. 2. Make all columns read only. 3. Use Ctrl+x, +v and +c key combinations.
1. Create RadGridView with hierarchy. 2. Set UseScrollbarsInHierarchy property to true. 3. Handle the CellDoubleClick event. 4. Run the project, open a child view and double click on its scrollbar. The CellDoubleClick event will fire which is wrong.
Filtering does not work correctly when NotConains and Contains filters are combined.
Work around:
private void radGridView1_FilterExpressionChanged(object sender, FilterExpressionChangedEventArgs e)
{
List<string> filterExpressions = new List<string>();
for (int i = 0; i < this.radGridView1.FilterDescriptors.Count; i++)
{
FilterDescriptor descriptor = this.radGridView1.FilterDescriptors[i];
string expression = null;
CompositeFilterDescriptor compositeFilterDescriptor = descriptor as CompositeFilterDescriptor;
if (compositeFilterDescriptor != null)
{
expression = CompositeFilterDescriptor.GetCompositeExpression(compositeFilterDescriptor);
}
else
{
expression = FilterDescriptor.GetExpression(descriptor);
}
if (!string.IsNullOrEmpty(expression))
{
filterExpressions.Add("(" + expression + ")");
}
}
string logicalOperator = (this.radGridView1.FilterDescriptors.LogicalOperator == FilterLogicalOperator.And) ? " AND " : " OR ";
string resultExpression = String.Join(logicalOperator, filterExpressions.ToArray());
e.FilterExpression = resultExpression;
}
Export to excel fails when there is null values for GridViewDateTimeColumn. The following code snippet reproduce the issue: ExportToExcelML export = new ExportToExcelML(gridView); export.HiddenColumnOption = HiddenOption.DoNotExport; export.HiddenRowOption = HiddenOption.DoNotExport; export.ExportVisualSettings = false; export.SheetMaxRows = ExcelMaxRows._1048576; export.RunExport(targetFileName);
FIX. RadGridViiew - HierarchyLevel property shows incorrect hierarchy level for GridNewRowElement in grid with hierarchy.
Object-hierarchy produces same child rows for every parent row.
If RadDropDownListEditor has DropDown style and you write a value which exists in the underline data source, it does not become current value.
The summary aggregate expression IIF(SUM(RecordCount) = 0, 0, 1/SUM(RecordCount)) causes exception in RadGridView.
GridView “decimal column - Current value “500”- Input “1.2.3.4” Scenario case: 1. Approaching to the target cell by “Mouse click directly on the input cell” then key in “1.2.3.4” and Enter à Display “500” as original value2. Approaching to target cell by “Tab or moving cursor to input cell” then key in “1.2.3.4” and Enter à Display “1” as only display the first input digit only
Scrolling when column reorder is performed does not work in hierarchy mode.