Hi,
I'm trying to read the value of selectedPoint.DataItem in RadCartesianChartView when selecting the bar.
DataPoint selectedPoint = e.P0.SelectedDataPoint();
var dataItem = selectedPoint.DataItem;
public class CastJavaObject
{
public static T Cast<T>(Java.Lang.Object? obj) where T : class
{
var propInfo = obj.GetType().GetProperty("Instance");
return propInfo == null ? null : propInfo.GetValue(obj, null) as T;
}
}
var poco = CastJavaObject.Cast<Result>(dataItem);
Hi,
I've added 3 different bar series to RadCartesianChartView and added ChartSelectionBehavior like
RadCartesianChartView chartView = new RadCartesianChartView(this); BarSeries barSeries = new BarSeries(); BarSeries barSeries1 = new BarSeries(); BarSeries barSeries2 = new BarSeries(); barSeries.CombineMode = ChartSeriesCombineMode.Stack; barSeries.CategoryBinding = new MonthResultDataBinding("Month"); barSeries.ValueBinding = new MonthResultDataBinding("Result"); barSeries.SelectedFillColor = Color.Green; barSeries.SelectedStrokeColor = Color.Red; barSeries.SelectedStrokeWidth = 5; barSeries.Data = (Java.Lang.IIterable)this.monthResults; chartView.Series.Add(barSeries); barSeries1.CombineMode = ChartSeriesCombineMode.Stack; barSeries1.CategoryBinding = new MonthResultDataBinding("Month"); barSeries1.ValueBinding = new MonthResultDataBinding("Result1"); barSeries1.SelectedFillColor = Color.Blue; barSeries1.SelectedStrokeColor = Color.Red; barSeries1.SelectedStrokeWidth = 5; barSeries1.Data = (Java.Lang.IIterable)this.monthResults;
chartView.Series.Add(barSeries1); barSeries2.CombineMode = ChartSeriesCombineMode.Stack; barSeries2.CategoryBinding = new MonthResultDataBinding("Month"); barSeries2.ValueBinding = new MonthResultDataBinding("Result2"); barSeries2.SelectedFillColor = Color.Orange; barSeries2.SelectedStrokeColor = Color.Red; barSeries2.SelectedStrokeWidth = 5; barSeries2.Data = (Java.Lang.IIterable)this.monthResults; chartView.Series.Add(barSeries2); ChartSelectionBehavior selectionBehavior = new ChartSelectionBehavior(); selectionBehavior.DataPointsSelectionMode = ChartSelectionMode.Single; chartView.Behaviors.Add(selectionBehavior);
While selecting the bar it selects only one barseries value. How can I select the 3 barseries values on single click.
Hi,
List view is not rendering on the iphone/Simulator with iOS 16
When i try to load it on ipad with ios14, it was working fine.
I see below errors in output when debugging in VS2022
*** Assertion failure in -[TKCollectionView _Bug_Detected_In_Client_Of_UICollectionView_Invalid_Batch_Updates:], UICollectionView.m:10064
*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Invalid batch updates detected: the number of sections and/or items returned by the data source before and/or after performing the batch updates are inconsistent with the updates.
Please advise if this is known issue.
Xamarin Control Version - 2021.1.413.0
iOS SDK - 16.4/15.5
Thank you
Balwinder
Hi Team,
Could you please help me how to scroll the RadCartesianChartView horizontally in Xamarin.Android.
Thank you!
I keep running into:
Java.Lang.RuntimeException: Font asset not found Fonts/telerikfont.ttf
When trying to access any page with an AutoCompleteView.
I'm not sure why this started happening. This used to work fine and I never had to include any sort of Telerik fonts in my project, nor do I reference any. I tried downloading the font and including it where it wanted (Assets/Fonts/telerikfont.ttf) and it still barks at me as if it doesn't see it.
Hi, I have an issue with RadListView Pull To Refresh, it doesn't work for iOS after using MyControl. MyControl opens RadPopup.
Down below-written sommelier code, please help to fix the issue.
<Grid VerticalOptions="FillAndExpand" HorizontalOptions ="FillAndExpand" RowSpacing="0" BackgroundColor="Red">
<Grid.RowDefinitions>
<RowDefinition Height="{x:Static resource:UiConst.ViewSize45}"/>
<RowDefinition Height="{x:Static resource:UiConst.ViewSize1}"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<StackLayout Grid.Row="0" Margin="10, 3, 0, 0" >
//do something
</StackLayout>
<BoxView Grid.Row="1" />
<datacontrols:RadListView x:Name="listview" BackgroundColor="Azure" Margin="0, 0, 0, 1"
Grid.Row="2" HorizontalOptions = "FillAndExpand" VerticalOptions = "StartAndExpand"
IsItemSwipeEnabled="True"
ItemSwipeCompleted="OnItemSwipeCompleted"
ItemSwipeStarting ="Listview_ItemSwipeStarting"
ItemsSource="Item"
SelectionMode="None"
ItemTapped="ItemTapped"
SwipeOffset="75,0,0,0" SwipeThreshold="10"
RefreshRequested="RadListView_RefreshRequested"
IsPullToRefreshEnabled="True" IsPullToRefreshActive="false">
<datacontrols:RadListView.ItemTemplate>
<DataTemplate>
<listview:ListViewTemplateCell>
<listview:ListViewTemplateCell.View>
<Grid HorizontalOptions="FillAndExpand" VerticalOptions="Center" Margin="0, 0, 0, -5">
<Grid.BackgroundColor>
<Binding Path="ReadTimeStamp" Mode="TwoWay">
<Binding.Converter>
<conv:NullToObjectConverter x:TypeArguments="Color"
NullObject="blue"
NotNullObject="white"/>
</Binding.Converter>
</Binding>
</Grid.BackgroundColor>
<Grid.RowDefinitions>
<RowDefinition Height="70"/>
<RowDefinition Height="1"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="80"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="80"/>
</Grid.ColumnDefinitions>
<Frame Grid.Column="0" Grid.Row="0" Margin="10, 5, 10, 0" >
<StackLayout>
<svg:SvgCachedImage />
<Label Text="text"/>
</StackLayout>
</Frame>
<StackLayout Grid.Column="1" Grid.Row="0" Margin="5, 10, 5, 0" >
<Label Text=""/>
<Label Text=""/>
</StackLayout>
<StackLayout Grid.Column="2" Grid.Row="0" Margin="0, 10, 5, 0" >
<Grid >
<Frame >
<svg:SvgCachedImage />
</Frame>
<controls:MyControl"/>
</Grid>
<Label Text=""/>
</StackLayout>
<BoxView Grid.Column="0" Grid.Row="1" Grid.ColumnSpan="3"/>
</Grid>
</listview:ListViewTemplateCell.View>
</listview:ListViewTemplateCell>
</DataTemplate>
</datacontrols:RadListView.ItemTemplate>
<datacontrols:RadListView.ItemSwipeContentTemplate>
<DataTemplate>
<Grid Margin="0"
Padding="0"
ColumnSpacing="0"
RowSpacing="0"
BackgroundColor="">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="75"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<StackLayout >
<svg:SvgCachedImage
WidthRequest="30" HeightRequest="30"
Source="{Binding SwipeIconSource}"/>
<Label Text="">
</StackLayout>
</Grid>
</DataTemplate>
</datacontrols:RadListView.ItemSwipeContentTemplate>
</datacontrols:RadListView>
</Grid>
</Grid>