Telerik Forums
UI for Xamarin Forum
11 answers
260 views
Using of RadListView is crashing whole app, from time to time.
There is no exact reproduciable way, I'm using same set of data, and from time to time, while navigating to given page (that contains RadListView in UI), it's crashing whole app, with below stacktrace:

Xamarin caused by: android.runtime.JavaProxyThrowable: System.ArgumentException: Handle must be valid.
Parameter name: instance
Java.Interop.JniEnvironment.InstanceMethods.CallNonvirtualVoidMethod(JniObjectReference instance, JniObjectReference type, JniMethodInfo method, JniArgumentValue* args)<bd30a18775d94dc8b6263aecd1ca9077>:0
Android.Runtime.JNIEnv.CallNonvirtualVoidMethod(IntPtr jobject, IntPtr jclass, IntPtr jmethod, JValue* parms)<d855bac285f44dda8a0d8510b679b1e2>:0
Com.Telerik.Widget.List.RadListView.RemoveBehavior(ListViewBehavior p0)<460da158265f4a9ab30bfc20f66f4cef>:0
Telerik.XamarinForms.DataControlsRenderer.Android.ListViewRenderer.ClearBehaviors(RadListView oldControl)<c7cf335427f34b76a978796372f68e8d>:0
Telerik.XamarinForms.DataControlsRenderer.Android.ListViewRenderer.OnElementDetached(RadListView oldElement)<c7cf335427f34b76a978796372f68e8d>:0
Telerik.XamarinForms.Common.Android.AndroidRendererBase<S, T>.Dispose(bool disposing)<f447797ad1b04dc48aa8741bf7f44749>:0
Java.Lang.Object.Finalize()<d855bac285f44dda8a0d8510b679b1e2>:0

Sometimes it's crashing while adding/removing items behind list collection, and REFRESHING whole list - initializing new ObservableCollection with new objects set.

It's totally random crashing - it's crashing once per 20-30 doing the same clicking through app.
Lance | Senior Manager Technical Support
Telerik team
 answered on 26 Sep 2018
4 answers
334 views

I use LoadonDemand in RadListView. in Event_ListLoadonDemand I call get method which is triggered when user click the load more button at the end of the list. this works fine is Android. But in ios when button is clicked events are concat to the list but list scrolls to the top.  This is not the case in android. How to avoid the list scrolling to the top in ios?  

 

<telerikDataControls:RadListView x:Name="EventList"
                                      BackgroundColor="{StaticResource DarkGray}"
                                      ItemsSource="{Binding CalendarEvents,Mode=TwoWay}"
                                      VerticalOptions="FillAndExpand"
                                      HorizontalOptions="FillAndExpand"
                                      IsLoadOnDemandEnabled="True"
                                      LoadOnDemandMode="Manual"
                                      IsPullToRefreshEnabled="True"
                                      RefreshRequested="EventList_RefreshRequested"
                                      LoadOnDemand="EventList_LoadOnDemand"
Yana
Telerik team
 answered on 25 Sep 2018
7 answers
332 views

Hi, is it possible navigate between tabs moving left/right with the fingers? like a carousel.

Thank you.

Lance | Senior Manager Technical Support
Telerik team
 answered on 21 Sep 2018
3 answers
146 views

how to apply translation to "load more" text appear when LoadOnDemand Manual at the end of the list view.?

 

Lance | Senior Manager Technical Support
Telerik team
 answered on 19 Sep 2018
20 answers
432 views

Hi There,

 I have ​implemented a Telerik Xamarin Forms Listview with custom cells. The group headers and cells have text in each that can grow and shrink depending on the amount of text in the record. This works perfectly on android but on IOS all the cells (Headers and Data Rows) are exactly the same height. Xamarin Forms Listview has a property called "HasUnevenRows" which takes care of this issue. Is there such a property in the Telerik Xamarin Forms Listview?

Didi
Telerik team
 answered on 18 Sep 2018
2 answers
646 views
Is it possible to have rows size dynamically based on their content and to set a minimum height?
Ian
Top achievements
Rank 1
 answered on 18 Sep 2018
2 answers
59 views

Hello,

Working with xf calendar and have a calendar loaded with appointments defaulting to monthview.

When day is selected, it have it move to dayview using the "SelectionChange" event:

calendar.TrySetViewMode(CalendarViewMode.Day, true);

 

Question is, how do I allow users to navigate BACK to monthview? 

Jason
Top achievements
Rank 1
 answered on 18 Sep 2018
3 answers
149 views

Hi, 

I want to hide more button and I can not find the way.

Thanks.

Lance | Senior Manager Technical Support
Telerik team
 answered on 14 Sep 2018
3 answers
60 views

I have a subclass of CalendarDayCell on Android and I'm trying to set the text color in an override of UpdateTextColor. The method takes two integers. What do they do? I've tried setting both to my desired color but the text is always black.

Didi
Telerik team
 answered on 14 Sep 2018
10 answers
417 views

i am able to bind data to a data grid using data templates but i am trying to get in a position to start selecting items from the grid, how can i do this using the

RadDataGrid for Xamarin forms: 

Xaml : 

<dg:RadDataGrid SelectionMode="Single"                         
                        Margin="0,20,0,0" 
                        HorizontalOptions="Center" 
                        SelectionUnit="Row" x:Name="grid_Source">
        </dg:RadDataGrid>

 

Code Behind - 

List<MetaData> src = new List<MetaData>();
            src.Add(new MetaData { Id = "Data", Caption = "Data" });
            src.Add(new MetaData { Caption = "Select", Id = "Select" });
            src.Add(new MetaData { Caption = "OperatorNo", Id = "OperatorNo" });
            src.Add(new MetaData { Caption = "OperatorName", Id = "OperatorName" });

            foreach (MetaData columns in src)
            {
                String propertyName = $"[{columns.Id}].Value";
                Telerik.XamarinForms.DataGrid.DataGridTemplateColumn text_Column = 
                    new Telerik.XamarinForms.DataGrid.DataGridTemplateColumn();
                text_Column.HeaderText = columns.Caption;
                text_Column.Name = propertyName;
                text_Column.CellContentTemplate = GetTemplate(propertyName,"Button", columns.Caption);

                this.grid_Source.Columns.Add(text_Column);
            }
            
            this.grid_Source.SelectionUnit = Telerik.XamarinForms.DataGrid.DataGridSelectionUnit.Row;
            this.grid_Source.SelectionStyle = new Telerik.XamarinForms.DataGrid.DataGridBorderStyle
            {
                BackgroundColor = Color.Orange,
                BorderColor = Color.Orange,
                BorderThickness = new Thickness(2)
            };

            this.grid_Source.AutoGenerateColumns = false;

 

Data Template :

 

public DataTemplate GetTemplate(String psPropertyName, String ControlType, String ColumnCaption)
        {
            return new DataTemplate(() =>
            {
                View oView = null;
                Label oLabel = new Label()
                {
                    BackgroundColor = Color.Transparent,
                    TextColor = Color.Black,
                    VerticalOptions = LayoutOptions.FillAndExpand,
                    HorizontalOptions = LayoutOptions.FillAndExpand
                };
                oLabel.SetBinding(Label.TextProperty, psPropertyName);

                oView = oLabel;
                return new Xamarin.Forms.StackLayout()
                {
                    Children = {
                                oView,
                },
                    Margin = new Thickness(0),
                    Padding = new Thickness(0),
                    HeightRequest = 50
                };
            });
        }

        

Lance | Senior Manager Technical Support
Telerik team
 answered on 13 Sep 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?