Hello,
I'm trying to implement list of medications grouped by first letter, like in attached example.
For this I'm using Radlistview with Sticky header, and so far everything looks good.
In addition we have a-z view on right side which should be updated on scroll.
Can we somehow detect which group is curently sticked, that we can update this view?
Or there is some other control that can provide us a-z view on side?
Best,
Jovana
Hi Support,
I have a RadAutoCompleteView (see below definitions) and everything works except when the item is too long and it spans 2 rows in the result view. When user selects this long item and the drop down is closed, the selected item text is right aligned in the control. For example, the item shows like this in the drop down box:
1st line - Nursing and residential care facilities
2nd line - and long term care homes
User selects this item and returns to the control, they only see:
"facilities and long term care homes". User will need to press the home button in order to go to the start of the text.
How do I code it so that the text is automatically left justified once returned from the result view into the control? Please help.
<telerikInput:RadAutoCompleteView x:Name="MainAutoCompleteSectors"
HeightRequest="35"
NoResultsMessage="No results."
BorderThickness="1"
BorderColor="Silver"
SuggestionViewHeight="150"
ItemsSource="{Binding Sectors}"
TextSearchPath="CombinedName"
BackgroundColor="White"
SuggestMode="Suggest"
CompletionMode="Contains"
Watermark="Start typing here to start search..."
WatermarkTextColor="Black"
TextChanged="AutoCompleteSectors_TextChanged"
FontSize="12"
SearchThreshold="2"
TextColor="Black"
SuggestionItemTextColor="Black"
SuggestionItemSelected="Handle_SuggestionSectorItemSelected"
HorizontalOptions="FillAndExpand">
<telerikInput:RadAutoCompleteView.SuggestionItemTemplate>
<DataTemplate>
<ViewCell>
<autoCompleteView:SuggestionItemLabel TextColor="Black"
Padding="5,0"
HighlightTextColor="{StaticResource OrangeTextColor}"
UnformattedText="{Binding CombinedName}"
HighlightText="{Binding Source={x:Reference MainAutoCompleteSectors}, Path=Text}"/>
</ViewCell>
</DataTemplate>
</telerikInput:RadAutoCompleteView.SuggestionItemTemplate>
</telerikInput:RadAutoCompleteView>
Hi support,
We would like to create a response drop down where we allow users to search for an item in the list. The drop down is bind to an observable collection in the VM called Response. Please see the definition of the combo box Response below.
It seems to be working fine. User is able to search and select an item and the selected item is bound to ResponseSelected as specified. The only problem we are having is when the user clicks on the control but did not select an item and clicks on another combo box with similar definitions (see Employees combo box below). The application hangs and it looks like it went into an infinite loop. This 'hanging' issue also appears if you keep clicking on the combo box (either Response or Employees) multiple times.
If we change IsEditable in the combo box definitions to False on both combo boxes, the hanging issue goes away. Are we doing something wrong? Please help.
<telerikInput:RadComboBox Grid.Row="0" Grid.Column="0"
ItemsSource="{Binding Response}" DropDownBackgroundColor="White"
DisplayMemberPath="Description"
TextColor="{StaticResource SilverTextColor}"
SearchTextPath="Description"
SearchMode="Contains"
Placeholder="select a response..."
PlaceholderColor="White"
FontSize="12"
SelectionMode="Single"
HorizontalOptions="FillAndExpand"
Margin="10,5,10,0"
SelectedItem="{Binding ResponseSelected, Mode=TwoWay}"
HighlightTextColor="DarkOrange"
IsDropDownClosedOnSelection="True"
IsEditable="True">
<telerikInput:RadComboBox.SelectedItemTemplate>
<DataTemplate>
<StackLayout BackgroundColor="White">
<Label Text="{Binding Description}" Style="{StaticResource labelStyle}" Margin="5,5,0,5" TextColor="Black" />
</StackLayout>
</DataTemplate>
</telerikInput:RadComboBox.SelectedItemTemplate>
</telerikInput:RadComboBox>
<telerikInput:RadComboBox ItemsSource="{Binding Employees}" DropDownBackgroundColor="White"
I just used the approach outlined in the link below to set a custom color for the selected row in my RadGridView control.
WPF DataGrid | SelectedBackground and MouseOverBackground | Telerik UI for WPF
This approach seems to have worked just fine for the case when the user clicks on a row to select it. However, when the SelectedItem property of the grid view is set in code through data binding, the selected row color reverts to the default value. Only upon clicking the row again does it display using the color that I defined.
Am I missing something?
Thanks!
Object reference not set to an instance of an object at Telerik.XamarinForms.Common.Data.LocalDataSourceProvider.ProcessCollectionChanged (System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x0000f] in <9e9b25dc0d3245a29ae02ea29570dc43>:0 at Telerik.XamarinForms.Common.Data.LocalDataSourceProvider.ProcessPendingChanges () [0x0001b] in <9e9b25dc0d3245a29ae02ea29570dc43>:0 at Telerik.XamarinForms.Common.Data.LocalDataSourceProvider.OnCompleted (System.Object sender, Telerik.XamarinForms.Common.Data.DataEngineCompletedEventArgs e) [0x00027] in <9e9b25dc0d3245a29ae02ea29570dc43>:0 at Telerik.XamarinForms.Common.Data.ParallelDataEngine.RaiseCompleted (Telerik.XamarinForms.Common.Data.DataEngineCompletedEventArgs args) [0x0000f] in <9e9b25dc0d3245a29ae02ea29570dc43>:0 at Telerik.XamarinForms.Common.Data.ParallelDataEngine.ProcessBottomLevelsParallel (System.Threading.Tasks.Task`1[TResult] bottomLevelResultsTask, Telerik.XamarinForms.Common.Data.ParallelState parallelState) [0x0016d] in <9e9b25dc0d3245a29ae02ea29570dc43>:0 at Telerik.XamarinForms.Common.Data.ParallelDataEngine+<>c__DisplayClass99_0.<BeginParallelProcessing>b__1 (System.Threading.Tasks.Task`1[TResult] task) [0x00000] in <9e9b25dc0d3245a29ae02ea29570dc43>:0 at System.Threading.Tasks.ContinuationTaskFromResultTask`1[TAntecedentResult].InnerInvoke () [0x00024] in <32cbdb1c0c3b4511b16bf95f79c88845>:0 at System.Threading.Tasks.Task.Execute () [0x00000] in <32cbdb1c0c3b4511b16bf95f79c88845>:0
Hi,
I'm trying to change the text color & size of RadListPicker popup,
ItemStyle="{StaticResource ItemStyle}"
<Style TargetType="telerikDataControls:SpinnerItemView" x:Key="ItemStyle">
<Setter Property="BackgroundColor" Value="#2a3137"/>
<Setter Property="TextColor" Value="#f00" />
<Setter Property="FontSize" Value="14"/>
</Style>
these highlighted values are not applying to the view, but BackgroundColor applying...
Please give me a solution to this issue.
Thanks
Hi,
I'm trying to change the color of telerikInput:RadAutoCompleteView close icon, default it's dark,
I need to assign a color to it, can anyone help me
Hi,
i am trying to create a graph, as can be seen in picture Chart.png.
But i found no property to set the start value of the logarithmic axis (default start value is 1 but i need 125).
How can i change the display range of the TKChartNumericAxis? And it is possible to invert the y axis (like in the screenshot)?
var chart = new TKChart
{
XAxis = new TKChartLogarithmicAxis
{
LogarithmBase = 2
},
YAxis = new TKChartNumericAxis(NSObject.FromObject(-10), NSObject.FromObject(120)),
Frame = StackLayout.Bounds.ToRectangleF()
};
chart.Title.Hidden = true;
chart.Legend.Hidden = true;
var list = new NSObject[]
{
new TKChartDataPoint(new NSNumber(500), new NSNumber(70)),
new TKChartDataPoint(new NSNumber(1000), new NSNumber(40)),
new TKChartDataPoint(new NSNumber(2000), new NSNumber(60)),
new TKChartDataPoint(new NSNumber(4000), new NSNumber(50))
};
var series = new TKChartLineSeries(list);
chart.AddSeries(series);
I am working on Xamarin Forms and I have to create a Datagrid programmatically with dynamic custom control where controls may have selected value or default value. Here column and controls are not predefined. I have asked two more questions before regarding this issue and the Telerik forum really helped me out. But the scenario is something else. Whenever I load Datagrid with existing data it is unable to keep row identity, all of those rows hold the same view with the same default/selected value as well. Is there any other way to bind new rows with dynamic custom controls instead of adding new data in ItemsSource.
My current approach is:
private readonly RadDataGrid dataGrid = new RadDataGrid() { IsEnabled = true, AutoGenerateColumns = false, HeightRequest = Application.Current.MainPage.Height * 57 / 100, IsClippedToBounds = true };
private ObservableCollection<dynamic> dataSource = new ObservableCollection<dynamic>();
private List<Element> Elements = new List<Element>();
public async Task DoSetup()
{
dataGrid.SelectionMode = DataGridSelectionMode.Single;
dataGrid.SelectionUnit = DataGridSelectionUnit.Row;
//dataGrid. += (s, e) => DataGrid_SelectionChanged(s, e);
dataGrid.UserFilterMode = DataGridUserFilterMode.Disabled;
dataGrid.UserGroupMode = DataGridUserGroupMode.Disabled;
dataGrid.UserSortMode = DataGridUserSortMode.None;
dataGrid.ItemsSource = dataSource;
AddHeaderRow();
}
private void AddHeaderRow()
{
var columnWidth = (Application.Current.MainPage.Width - 25) / Elements.Count;
this.dataGrid.Columns.Add(new DataGridTemplateColumn
{
SizeMode = DataGridColumnSizeMode.Fixed,
Width = 25,
Name = "actionbtn",
CanUserFilter = false,
CanUserGroup = false,
CanUserSort = false,
CanUserEdit = true,
HeaderStyle = new DataGridColumnHeaderStyle
{
OptionsButtonTextColor = Color.Transparent,
OptionsButtonFontSize = 0,
BorderColor = Color.FromHex("#D9D9D9"),
BorderThickness = new Thickness(0)
},
CellContentTemplate = GetActionButtonIcon() //return trash icon
});
foreach (ApiClient.Models.IElement element in Elements)
{
this.dataGrid.Columns.Add(new DataGridTemplateColumn
{
SizeMode = DataGridColumnSizeMode.Fixed,
Width = columnWidth,
HeaderText = element.DisplayName,
Name = element.DisplayName,
CanUserFilter = false,
CanUserGroup = false,
CanUserSort = false,
CanUserEdit = true,
HeaderStyle = new DataGridColumnHeaderStyle
{
OptionsButtonTextColor = Color.Transparent,
OptionsButtonFontSize = 0,
BorderColor = Color.FromHex("#D9D9D9"),
BorderThickness = new Thickness(0)
},
CellContentTemplate = GetTemplate(element)
});
}
}
private DataTemplate GetTemplate(Element element)
{
return new DataTemplate(() =>
{
var stackLayout = new StackLayout();
var view = GetView(element); //return dynamic custom controls based on element type
stackLayout.Children.Add(view);
return stackLayout;
});
}
DataTemplateSelector may solve this issue, but didn't find any solution yet using DataTemplateSelector.