In this particular case, setting the IsAIEnabled property to false does not hide the PromptInput element in the following themes:
- Aqua
- Desert
- HighContrastBlack
- Office2007Black
- Office2010Silver
- Windows7
As a workaround, the PromptInput element can be removed by setting its visibility property to Collapsed:
gridView1.GridViewElement.PromptInputElement.Visibility = ElementVisibility.Collapsed;
I was trying to move the NewRow to the bottom of the RadVirtualGrid. This is also supported by its big brother RadGridView. I have now learned that this is not supported by RadVirtualGrid.
Hereby my request: Please support this!
I've created a Harmony patch (which works for me); it might help you if you decide to support it:
static class MoveNewRowToBottom
{
[HarmonyPatch(typeof(VirtualGridTableElement), "InvalidatePinnedRows")]
static class VirtualGridTableElement_InvalidatePinnedRows
{
static private bool _isInvalidating;
static private bool Prefix(VirtualGridTableElement __instance)
{
if (_isInvalidating)
return false;
_isInvalidating = true;
__instance.ViewElement.TopPinnedRows.DisposeChildren();
__instance.ViewElement.BottomPinnedRows.DisposeChildren();
var viewInfo = __instance.ViewInfo;
var rowsViewState = __instance.RowsViewState;
var topPinnedItems = rowsViewState.TopPinnedItems;
var bottomPinnedItems = rowsViewState.BottomPinnedItems;
if (viewInfo.ShowFilterRow)
if (!topPinnedItems.Contains(RadVirtualGrid.FilterRowIndex) && !bottomPinnedItems.Contains(RadVirtualGrid.FilterRowIndex))
rowsViewState.SetPinPosition(RadVirtualGrid.FilterRowIndex, PinnedRowPosition.Top);
if (viewInfo.ShowNewRow)
if (!topPinnedItems.Contains(RadVirtualGrid.NewRowIndex) && !bottomPinnedItems.Contains(RadVirtualGrid.NewRowIndex))
rowsViewState.SetPinPosition(RadVirtualGrid.NewRowIndex, PinnedRowPosition.Top);
if (viewInfo.ShowHeaderRow)
if (!topPinnedItems.Contains(RadVirtualGrid.HeaderRowIndex) && !bottomPinnedItems.Contains(RadVirtualGrid.HeaderRowIndex))
rowsViewState.SetPinPosition(RadVirtualGrid.HeaderRowIndex, PinnedRowPosition.Top);
var elementProvider = __instance.RowScroller.ElementProvider;
var topPinnedRows = __instance.ViewElement.TopPinnedRows;
foreach (int topPinnedRow in topPinnedItems.SortTopRowIndexes())
{
VirtualGridRowElement pinnedRow = (VirtualGridRowElement)elementProvider.GetElement(topPinnedRow, null);
topPinnedRows.Children.Add(pinnedRow);
pinnedRow.Attach(topPinnedRow, null);
}
var bottomPinnedRows = __instance.ViewElement.BottomPinnedRows;
foreach (int bottomPinnedRow in bottomPinnedItems.SortBottomRowIndexes())
{
VirtualGridRowElement pinnedRow = (VirtualGridRowElement)elementProvider.GetElement(bottomPinnedRow, null);
bottomPinnedRows.Children.Add(pinnedRow);
pinnedRow.Attach(bottomPinnedRow, null);
}
_isInvalidating = false;
return false;
}
}
static private IEnumerable<int> SortTopRowIndexes(this ReadOnlyCollection<int> topRowIndexes)
{
var specialRowIndex = topRowIndexes.Where(index => index < 0).ToList();
if (specialRowIndex.Contains(RadVirtualGrid.HeaderRowIndex))
yield return RadVirtualGrid.HeaderRowIndex;
if (specialRowIndex.Contains(RadVirtualGrid.NewRowIndex))
yield return RadVirtualGrid.NewRowIndex;
if (specialRowIndex.Contains(RadVirtualGrid.FilterRowIndex))
yield return RadVirtualGrid.FilterRowIndex;
foreach (var index in topRowIndexes.Where(index => index >= 0))
yield return index;
}
static private IEnumerable<int> SortBottomRowIndexes(this ReadOnlyCollection<int> bottomRowIndexes)
{
foreach (var index in bottomRowIndexes.Where(index => index >= 0))
yield return index;
var specialRowIndex = bottomRowIndexes.Where(index => index < 0).ToList();
if (specialRowIndex.Contains(RadVirtualGrid.FilterRowIndex))
yield return RadVirtualGrid.FilterRowIndex;
if (specialRowIndex.Contains(RadVirtualGrid.NewRowIndex))
yield return RadVirtualGrid.NewRowIndex;
if (specialRowIndex.Contains(RadVirtualGrid.HeaderRowIndex))
yield return RadVirtualGrid.HeaderRowIndex;
}
}
Hi,
when I select the column chooser multiple times via context menu, the column chooser dialog scales multiple times.
Reproduced here with the Telerik sample application. 150 % dpi scaling.
Regards
Erwin
In the ControlDefault theme, editor cell text is misaligned while editing a cell.
How to reproduce: 1. Run the Mail Merge example (QSF) 2. Select the image inside the document and move it to another position
The specified format in the DisplayFormat attribute should be considered when automatically generating the GridViewDateTimeColumn.
public RadForm1()
{
InitializeComponent();
List<Item> items = new List<Item>();
for (int i = 0; i < 5; i++)
{
items.Add(new Item(DateTime.Now.AddDays(i)));
}
this.radGridView1.DataSource = items;
this.radGridView1.AutoSizeColumnsMode = Telerik.WinControls.UI.GridViewAutoSizeColumnsMode.Fill;
}
public class Item
{
[System.ComponentModel.DisplayName("My Date")]
[System.ComponentModel.DataAnnotations.DisplayFormat(DataFormatString = "{0:MM/dd/yyyy}")]
public DateTime Date { get; set; }
public Item(DateTime date)
{
this.Date = date;
}
}
This item is migrated to the Telerik Document Processing portal: http://feedback.telerik.com/Project/184/Feedback/Details/190130 Please use the new item for commenting, voting and subscribing instead of this one.
We should consider the Display attribute when using business objects as data source in RadGridView.
1. Create a new project with RadChartView. 2. Add a Cartesian chart with a large number of points (10000 for example). 3. Set animations for every point. 4. Run the project - it will crash.
To reproduce:
- Add RadForm with RadMenu with some items
- set this.IsMdiContainer = true;
- Run and hit the close button -> note the while closing the title bar looses its theme
WORKAROUND:
radMenu1.IsMainMenu = false;
When user enter into a child record in a heiarchy RadGridView Jaws reads DBNull. When user go back, the proper field is read.
Import the following code: <ol> <li>Coffee</li> <li></li> <li>Milk</li> </ol
Multiply line text is not correct align at the left side when control runs on Win xp. Steps to reproduce: this.radTextBoxControl1.Text = "This\nis a\ntest";
1. Create new project and add RadTextBox inside a user control. 2. Set its Dock property to Left. 3. Add custom button items in its layout by using RadButtonElement and StackLayoutElement. 4. Set a default value to the text box when handling the form Load event. 5. Run the project.
If I add a RadLabel to a RadPanel, and set the panel AutoScroll to true, scrolling the panel will cause lines to appear. The words get clipped.
When a RadRichTextBox control is added as a child to RadCalendar, the Space and Enter key input is stolen by the calendar. Workaround is available here: http://www.telerik.com/community/forums/getting-visible-dates-from-radcalendar