Hi Telerik team,
We are having a rad-combo box control implemented in a pop up, where the user will be able to select one item from the list based on the Alphabets entered by the User.
Let us consider the user is entering 'OLI' in the combo box.
The drop down list appears for the entered Alphabets, but when the user tries to add more Alphabet to it, already entered 'OLI' gets cleared and the user entered new alphabets is appearing, which should not.
I have attached the image(RadCombo box Focus Issue.jpeg)
We found that as soon as the user stops entering the Alphabet, the control selects the whole Alphabets already entered(Blue Selection). - which should not and the user have to press the Right Arrow to get the focus to the last alphabet to add more alphabet the existing text.
Any Possibility to change the behavior so that when the user stops entering the alphabet the focus is set next of the last character entered.
The Xaml Code Used is
<telerik:RadComboBox
Name="NameCombo"
HorizontalAlignment="Left"
VerticalAlignment="Center"
HorizontalContentAlignment="Left"
BorderBrush="#F1F1F1"
EmptyText="Type to Search Name"
IsDropDownOpen="{Binding IsDropDownOpen, Mode=TwoWay}"
IsEditable="True"
IsTextSearchCaseSensitive="False"
Text="{Binding NameSearchText, Mode=TwoWay}"
TextSearchMode="Contains">
<telerik:RadComboBoxItem>
<telerik:RadComboBoxItem.Template>
<ControlTemplate>
<Grid>
<telerik:RadBusyIndicator BusyContent="Loading..." IsBusy="{Binding IsNameLoading}">
<telerik:RadGridView
Width="455"
MaxHeight="150"
behavior:ControlEventsCommand.RadGridSelectionChangedEvent="{Binding NameSelectionChangedCommand}"
AutoGenerateColumns="False"
CanUserFreezeColumns="False"
CanUserInsertRows="False"
CanUserResizeColumns="False"
CanUserSortColumns="False"
IsFilteringAllowed="False"
IsReadOnly="True"
ItemsSource="{Binding NameList}"
RowIndicatorVisibility="Collapsed"
ScrollViewer.VerticalScrollBarVisibility="Auto"
SelectedItem="{Binding SelectedName, Mode=OneWayToSource}"
ShowGroupPanel="False">
<telerik:RadGridView.Columns>
<telerik:GridViewDataColumn
Width="450"
Header="Name"
HeaderCellStyle="{StaticResource NameClassHeader}">
<telerik:GridViewColumn.CellTemplate>
<DataTemplate>
<TextBlock
Text="{Binding Name}"
TextTrimming="WordEllipsis"
ToolTip="{Binding Name}"
ToolTipService.IsEnabled="True"
ToolTipService.ShowOnDisabled="False">
<TextBlock.Style>
<Style TargetType="TextBlock">
<Style.Triggers>
<DataTrigger Binding="{Binding Name}" Value="">
<Setter Property="IsEnabled" Value="False" />
</DataTrigger>
</Style.Triggers>
</Style>
</TextBlock.Style>
</TextBlock>
</DataTemplate>
</telerik:GridViewColumn.CellTemplate>
</telerik:GridViewDataColumn>
</telerik:RadGridView.Columns>
</telerik:RadGridView>
</telerik:RadBusyIndicator>
</Grid>
</ControlTemplate>
</telerik:RadComboBoxItem.Template>
</telerik:RadComboBoxItem>
</telerik:RadComboBox>
Thanks In Advance!
Regards,
KishoreKumar
Hi,
I want to call different functions based on RadSaveFileDialog's FilterIndex but I'm having trouble getting the correct FilterIndex when trying to save a file. The filter shows up correctly on the dialog but whenever I click Save button, the dialog's FilterIndex is 0, instead of the expected values 1 or 2.
Using the same code, FilterDialog correctly gets set with Windows SaveFileDialog. Is there a known issue with this or could this be related to not setting the Owner property?
Thanks!
I have setup a diagram using the Sugiyama Layout. I have added 50 Rounded Rectangle shapes (without connectors) in code behind. I am using the following code to size the shapes to fit the diagram:
Rect allShapesBounds = Diagram1.Shapes.GetEnclosingBounds(); Rect inflatedRect = allShapesBounds.InflateRect(10, 10, 10, 10); Diagram1.BringIntoView(inflatedRect, false);
In the attached image Before.png you will see the 50 shapes all sized and lined up correctly. The After.png shows I moved the shape with the #1 is overlapping the others and there is a space where it used to reside. I tried calling the above code in the drag event handler but that returns the moved shape to it's original position. What do I need to do to achieve the results listed above?
Hi Team ,
I am new to WPF , we are using RadGridView to load data from View Model in WPF by using C# .
if selected a row and data grid refreshed or load with new items(rows) then selected row position is moving either up or down to row .
here vertical scroll bar position changed .
reproduce steps
1. Select any of the row from the grid.
2. Wait for the Lobby updates to happen and new tables get added to the grid
Expected:
XAML :
<telerik:RadGridView x:Name="PokerX_CashGames_RadGridView_LobbyGrid" ItemsSource="{Binding CashGamesCollection, UpdateSourceTrigger=PropertyChanged}"
SelectedItem="{Binding SelectedTableItem, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" Loaded="OnDataGridLoaded" Unloaded="OnDataGridUnloaded"
AutomationProperties.AutomationId="PokerX_CashGames_RadGridView_LobbyGrid">
<i:Interaction.Behaviors>
xaml.cs
private void OnDataGridDataUpdated(object datagridUpdateEventArgs)Please help me how can i fix this .
Hi Telerik Team,
I have some few question regarding telerik:RadMaskedDateTimeInput Control
telerik:RadMaskedDateTimeInput:
I have a telerik:RadMaskedDateTimeInput Control which has a default date as 08/09/21. We want to change the date to 31/10/2021.
When the user enters 31 in the date field, the control is taking the month into consideration and changing the date automatically to 30 since there is no 31 in the month of September.
So first I have to change the month field and then date field to get the new proposed date 31/10/2021.
Any Possibility to change the behaviour.
The property I have used is
<telerik:RadMaskedDateTimeInput
Culture="{x:Static globalization:CultureInfo.InvariantCulture}"
DataContext="{Binding Path=UiArrivalDateObject, Mode=TwoWay}"
FontSize="10"
InputBehavior="Replace"
IsClearButtonVisible="False"
Mask="dd/MM/yy HH:mm"
PreviewKeyDown="RadMaskedDateTimeInput_PreviewKeyDown"
SectionsNavigationMode="Cycle"
SelectionOnFocus="CaretToBeginning"
TextMode="PlainText"
UpdateValueEvent="PropertyChanged"
Value="{Binding Path=LiveDateBerth, Mode=TwoWay, UpdateSourceTrigger=LostFocus, Converter={StaticResource DateTimeOffsetToDateTimeConverter}}">
</telerik:RadMaskedDateTimeInput>
Thanks In Advance
Regards,
Kishore Kumar
I'm using a RadGrid / GridView and the performance is horrible.
I'm not doing anything fancy. I have 15 columns and about 2000 rows
In HTML, this is piece of cake, blazing fast and 200hz when scrolling.
in WPF this just sucks at 5 fps and a very laggy experience.
I'm reading through the optimization docs and there are somewhat 50+ nobs to turn in the hope that it makes a difference.
My humble request is therefore : Some Telerik Application Analyzer that scans through the program and finds all the problematic settings or constructions that hurt performance.
I guess it should be pretty simple to look at container element properties and instance properties of the RadGrid and tell the user which ones are hurting the performance or disabling scroll virtualization... coz i have no idea.
PS. One of the performance tips are completely impossible to correct:
Placing RadGridView in panels/controls which measure it with infinity disables the UI virtualization mechanism of the control and can greatly impact performance when dealing with large amounts of data. Examples of such panels include ScrollViewer, StackPanel and Grid with a definition with Width/Height set to Auto.
MANY UI-elements use Grid in their internal workings:
MainWindow - uses a Grid with height/width = auto
AdornerDecorator - uses a Grid with height/width = auto
Rootgrid - uses a Grid with height/width = auto
TabControl - uses a Grid with height/width = auto
TabItem - uses a Grid with height/width = auto
Border (Contentpresenter) - uses a Grid with height/width = auto
RadBusyIndicator - uses a Grid with height/width = auto
So how the heck am i supposed to correct all those problems without completely going insane and create a stinking pile of code ?
I want to draw a custom MajorLinesVisibility XY.
MajorLinesVisibility Not using XY, instead, when CategoricalAxis' PlotMode is BetweenTicks,
I want to draw vertical lines between items.
Please refer to the referenced image.
<telerik:RadCartesianChart x:Name="chart1" Palette="Flower" Margin="10">
<telerik:RadCartesianChart.HorizontalAxis>
<!--PlotMode="BetweenTicks"-->
<telerik:CategoricalAxis x:Name="catAxis" PlotMode="BetweenTicks" />
</telerik:RadCartesianChart.HorizontalAxis>
<telerik:RadCartesianChart.VerticalAxis>
<telerik:LinearAxis x:Name="verticalAxis" />
</telerik:RadCartesianChart.VerticalAxis>
<telerik:RadCartesianChart.Grid>
<telerik:CartesianChartGrid MajorLinesVisibility="XY" />
</telerik:RadCartesianChart.Grid>
<telerik:RadCartesianChart.Annotations>
<telerik:CartesianGridLineAnnotation Axis="{Binding ElementName=catAxis}"
Value="B" Stroke="Red" StrokeThickness="5" />
</telerik:RadCartesianChart.Annotations>
No video is shown when the camera starts and calling the TakeSnapshot method results in an exception in PresentationCore.CriticalFromVisual, with the message "parameter v cannot be null'.
I've provided a simple test app that reproduces the problem. Platform is Windows 10, and the app is a .NET 5.0 WPF app using the latest Telerik UI for WPF nuget package. I have tried AnyCPU, x64 and x86 and the behavior is the same for all configurations, both release and debug.
I have tested on a desktop machine with a Logitech 910 webcam and on a Surface Pro 3 using the internal camera. The identical code works fine on WPF .NET Framework 4.7.2 on both devices.
Project file is attached.
Here is the window xaml:
<Window x:Class="cameratest.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:cameratest"
xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
mc:Ignorable="d"
Title="MainWindow"
Height="450"
Width="800">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<Button Width="80"
Margin="4"
HorizontalAlignment="Left"
Click="OnSnapClick">Snap</Button>
<telerik:RadWebCam Grid.Row="1"
x:Name="radWebCam" />
</Grid>
</Window>
And the code behind:
using System.Collections.ObjectModel;
using System.Diagnostics;
using System.Windows;
using System.Windows.Media.Imaging;
using Telerik.Windows.Controls;
using Telerik.Windows.MediaFoundation;
namespace cameratest
{
/// <summary>
/// Interaction logic for MainWindow.xaml
/// </summary>
public partial class MainWindow : Window
{
public MainWindow()
{
InitializeComponent();
radWebCam.SnapshotTaken += RadWebCamOnSnapshotTaken;
radWebCam.CameraError += RadWebCamOnCameraError;
}
private void RadWebCamOnCameraError(object sender, CameraErrorEventArgs e)
{
Debug.WriteLine(e.Error.Message);
}
private void RadWebCamOnSnapshotTaken(object sender, SnapshotTakenEventArgs e)
{
BitmapSource snapshot = e.Snapshot;
}
private void OnSnapClick(object sender, RoutedEventArgs e)
{
radWebCam.TakeSnapshot();
}
}
}
Modifying the app to disable auto start and initialize and state the camera manually results in the same problem.
I'm trying to use the VirtualGrid to show a collection of read-only "record" objects in a report. The problem is that each "record" is just a List<object> whose count and types are not know until runtime. The column titles are stored separately in a different list of field descriptors.
I tried the CellValueNeeded approach (i.e. without using any sort of DataSource, custom or otherwise), and while my data showed up just fine in the grid, I had no titles on the columns. There doesn't seem to be any way to set the titles with this approach that I can see. There is no corresponding ColumnTitleNeeded event, no SetColumnTitle function and no collection of columns I can access. At least not that I can see
So how do I set the column titles in code behind?
(I should add that I also tried the Custom DataSource approach I looked at your VirtualGrid_WPF example in the SDK, but that seems to rely on the fact that each object representing a record ("Club" in the example) has property names and types that areknown at build time. I could not make it work at all. )