Telerik Forums
UI for Xamarin Forum
3 answers
730 views

 

Telerik 2018.2.620.2, MonoAndroid 8.0

getting an exception on android only: 
System.MissingMethodException: Default constructor not found for type Telerik.XamarinForms.DataControlsRenderer.Android.ListView.ListViewTemplateCellRenderer occurred

Added SkiaSharp.Views.Forms, doesn't seem to help.  

              <telerikDataControls:RadListView.ItemTemplate>
                    <DataTemplate>
                        <telerikListView:ListViewTemplateCell>
                            <telerikListView:ListViewTemplateCell.View>
                                <Grid Margin="20"> 

                                 </Grid>
                            </telerikListView:ListViewTemplateCell.View>
                        </telerikListView:ListViewTemplateCell>
                    </DataTemplate>
                </telerikDataControls:RadListView.ItemTemplate>

Jay
Top achievements
Rank 1
 answered on 10 Jul 2018
7 answers
150 views

 hi All 

There is a bug which was not in the previous version. i have a dataform defined like this 

 

<telerikInput:RadDataForm x:Name="dataForm">
                <telerikInput:RadDataForm.Source>
                    <local:Customer_UI_Modelcs />
                </telerikInput:RadDataForm.Source>
            </telerikInput:RadDataForm>

 

and my model for the UI is defined like this 

 

public  class Customer_UI_Modelcs
  {
      [NonEmptyValidator("Please fill Customer Name", "OK")]
      [DisplayOptions(Header = "Customer Name")]
      public string Customer_Name { get; set; }
 
      [NonEmptyValidator("Please fill Customer Surnamme", "OK")]
      [DisplayOptions(Header = "Customer Surnamme")]
      public string Customer_Surnamme { get; set; }
 
  }

 

and when this project is ran i get the following error 

Unhandled Exception:

Java.Lang.Error: The data form editor for property Customer_Name must have a constructor that accepts a RadDataForm and an EntityProperty.

 

This issue never existed in the previous version , i have another project where it does not happen . i am not sure what causes this. i have attached an example project 

 

Vuyiswa
Top achievements
Rank 2
 answered on 09 Jul 2018
7 answers
244 views
Good day,

 

I am trying to centralize all the styling information in my apps resource dictionary, but I am not able to use the resources to define the styles for the RadListView.

This works:

<telerikDataControls:RadListView.PressedItemStyle>
                <telerikListView:ListViewItemStyle BackgroundColor="#F2F2F2" BorderColor="#e9e9e9" BorderWidth="1" BorderLocation="Bottom"/>
            </telerikDataControls:RadListView.PressedItemStyle>

 

This does not work:

<telerikDataControls:RadListView.PressedItemStyle>
               <telerikListView:ListViewItemStyle BackgroundColor="{DynamicResource MedLightGrey}" BorderColor="{DynamicResource LightGrey}" BorderWidth="1" BorderLocation="Bottom"/>
           </telerikDataControls:RadListView.PressedItemStyle>

 

It gives me an error: "No property, bindable property, or event found for 'BackgroundColor' "

I also get the same issue when trying to define ListViewItemStyle in my Resource Dictionary.

Thanks & Regards
Cornelius Kruger

 

 

Lance | Senior Manager Technical Support
Telerik team
 answered on 09 Jul 2018
1 answer
55 views

     I have the following 

 

<telerikInput:RadDataForm  x:Name="dataForm" CommitMode="Immediate" >
                 </telerikInput:RadDataForm>

 

this renders correctly.   and i also have a Grid  below and on selected change i bind data to the Dataform and the data get binded correct, if i want to make a sure on the DataForm and Save the changes , i get the old value before the change was made. this was working correctly in the previous version. i have one example that is working , i compared and all the same . 

 

 

Lance | Senior Manager Technical Support
Telerik team
 answered on 09 Jul 2018
5 answers
216 views
Hello,

I am getting System.ArgumentNullException: Value cannot be null. on using RadListView with List<T> items.

I am using project with multiselect listview, and it is working with basic xamarin ListView, which I want to replace with telerik RadListView.

How I can correctly use RadListView instead of Listview in SelectMultipleBasePage.
ProjectMultiselectExample on github
Example of code:
public List<WrappedSelection<T>> WrappedItems = new List<WrappedSelection<T>>();
public SelectMultipleBasePage(List<T> items)
        {
            WrappedItems = items.Select(item => new WrappedSelection<T>() { Item = item, IsSelected = false }).ToList();
            ListView mainList = new ListView()
            {
                ItemsSource = WrappedItems,
                ItemTemplate = new DataTemplate(typeof(WrappedItemSelectionTemplate)),
            };

            mainList.ItemSelected += (sender, e) =>
            {
                if (e.SelectedItem == null) return;
                var o = (WrappedSelection<T>)e.SelectedItem;
                o.IsSelected = !o.IsSelected;
                ((ListView)sender).SelectedItem = null; //de-select
            };
            Content = mainList;
        }
Nikolay Demirev
Telerik team
 answered on 09 Jul 2018
3 answers
167 views

Hello, 

   Is it possible that i can display a sub group in a DataGrid (as show in the photo)?  I need to show the detail of one line when we clic sur this line.   In WPF we have RadGridView.HierarchyChildTemplate, but i didn't find this with Telerik Xamarin.  

   Could you please give me a exemple ?

Lance | Senior Manager Technical Support
Telerik team
 answered on 06 Jul 2018
3 answers
404 views

Hi,

My question actually is simple, I have a chart and I want to change/refresh it when change the picker but I am getting NoData

Here is my code

.xaml

  <Picker x:Name="picker" Title="Select a monkey" SelectedIndexChanged="picker_SelectedIndexChanged" SelectedIndex="{Binding Selectedindex, Mode=TwoWay}" VerticalOptions="StartAndExpand" Margin="4">
                <Picker.ItemsSource>
                    <x:Array Type="{x:Type x:String}">
                        <x:String>Baboon</x:String>
                        <x:String>Capuchin Monkey</x:String>
                        <x:String>Blue Monkey</x:String>
                        <x:String>Squirrel Monkey</x:String>
                        <x:String>Golden Lion Tamarin</x:String>
                        <x:String>Howler Monkey</x:String>
                        <x:String>Japanese Macaque</x:String>
                    </x:Array>
                </Picker.ItemsSource>
            </Picker>
 
<telerikChart:RadCartesianChart x:Name="chart" HorizontalOptions="CenterAndExpand">
                    <telerikChart:RadCartesianChart.BindingContext>
                        <local:Models.Chart/>
                    </telerikChart:RadCartesianChart.BindingContext>
                    <telerikChart:RadCartesianChart.HorizontalAxis>
                        <telerikChart:CategoricalAxis />
                    </telerikChart:RadCartesianChart.HorizontalAxis>
                    <telerikChart:RadCartesianChart.VerticalAxis>
                        <telerikChart:NumericalAxis />
                    </telerikChart:RadCartesianChart.VerticalAxis>
                    <telerikChart:RadCartesianChart.Series>
                        <telerikChart:BarSeries CategoryBinding="Category"
                        ValueBinding="Value"
                        ItemsSource="{Binding Data}" />
                    </telerikChart:RadCartesianChart.Series>
                </telerikChart:RadCartesianChart>

 

 

 

Chart.cs

public class Chart
  {
      public Chart()
      {
          this.Data = GetCategoricalData();
      }
 
      public ObservableCollection<CategoricalData> Data { get; set; }
 
      private static ObservableCollection<CategoricalData> GetCategoricalData()
      {
          var data = new ObservableCollection<CategoricalData>  {
          new CategoricalData { Category = "A", Value = 0.63 },
          new CategoricalData { Category = "B", Value = 0.85 },
          new CategoricalData { Category = "C", Value = 1.05 },
          new CategoricalData { Category = "D", Value = 0.96 },
          new CategoricalData { Category = "E", Value = 0.78 },
      };
 
          return data;
      }
  }
 
  public class CategoricalData
  {
      public object Category { get; set; }
 
      public double Value { get; set; }
  }
Lance | Senior Manager Technical Support
Telerik team
 answered on 05 Jul 2018
1 answer
91 views
Hello there - I am looking for a way to do basic Http requests on the Apple Watch, preferably (but not necessarily) using System.Net.Http
I know you guys would like to see some code, but I am convinced that the issue lies elsewhere
When run on the simulator the Http requests works perfectly. But when it is run on a physical Apple Watch the app always 'crashes' instantly. 
The app also 'crashes' if I surround the call using try/catch. I suspect that the app is not being crashed by a flaw in the code, but rather that the app is being suspended by the Apple Watch OS.
Maybe I need to fill in some entitlements for the Apple Watch to perform web calls?
Have anyone had any success performing web calls on an Apple Watch using Xamarin? Any pointers would be greatly appreciated 
Lance | Senior Manager Technical Support
Telerik team
 answered on 05 Jul 2018
0 answers
114 views

Hello Telerik,

 

I would like to remove border white of label pie chart in xamarin form, please help me.

khanhnd
Top achievements
Rank 2
 asked on 05 Jul 2018
1 answer
177 views

hi

I want append items to list when user scroll up through the listview. PullToRefresh works when user scrolling the list upwards only., 

Can this be achieved and if so how?   Following is my code which works fine on "pull".

<telerikDataControls:RadListView
   x:Name="Events"
   ItemsSource="{Binding CalendarEvents,Mode=TwoWay}"
   VerticalOptions="FillAndExpand"
   HorizontalOptions="FillAndExpand"
   IsLoadOnDemandEnabled="false"
   LoadOnDemandMode="Automatic"
   IsPullToRefreshEnabled="True"
   RefreshRequested="EventList_RefreshRequested"
   IsPullToRefreshActive="{Binding IsBusy,Mode=TwoWay}" >
 
 
 
  private void EventList_RefreshRequested(object sender, PullToRefreshRequestedEventArgs e)
  {
    GetEvents();
  }

 

Lance | Senior Manager Technical Support
Telerik team
 answered on 04 Jul 2018
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?