Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all 77050 articles
Browse latest View live

Blurred ContentView

$
0
0

I need a content view that blurs whatever is below it so I thought I'd try writing a custom control and an iOS renderer for it. This is the class definition ...

public class XBlurredContentView : ContentView
{
}

... here's the custom renderer ...

public class XBlurFrameRenderer : ViewRenderer<XBlurredContentView,UIView>
{
    private UIVisualEffectView _effectView;

    protected override void OnElementChanged(ElementChangedEventArgs<XBlurredContentView> e)
    {
        base.OnElementChanged(e);
        var blurFrame = e.NewElement;
        if (blurFrame != null)
        {
            var effect = UIBlurEffect.FromStyle(UIBlurEffectStyle.Light);
            _effectView = new UIVisualEffectView(effect);
            SetNativeControl(_effectView);
        }
    }

    protected override void OnElementPropertyChanged(object sender, PropertyChangedEventArgs e)
    {
        if (e.PropertyName == VisualElement.XProperty.PropertyName
            || e.PropertyName == VisualElement.YProperty.PropertyName
            || e.PropertyName == VisualElement.HeightProperty.PropertyName
            || e.PropertyName == VisualElement.WidthProperty.PropertyName)
        {
            var x = Element.X; var y = Element.Y; var w = Element.Width; var h = Element.Height;
            _effectView.Frame = new CGRect(x, y, w, h);
        }
        base.OnElementPropertyChanged(sender, e);
    }
}

... and here's the XAML to test it ...

    <customUi:XBlurredContentView HeightRequest="50">
        <Grid>
            <Button Text="Hello World" TextColor="White" />
        </Grid>
    </customUi:XBlurredContentView>

The expected are does get blurred as expected but the content (the "Hello World" button isn't visible. I double checked with the Live Inspector and it does look like the button (and it's UILabel) is added correctly but nothing is visible on screen. This is my first go at deriving the ContentView into a custom control so I guess I need to learn more but what have I missed?


Xamarin Forms Zoom in Zoom out in Web view Does not work Smoothly

$
0
0

I an Custom Render Webview In that I load a Pdf. When that Pdf is trying to zoom in or zoom out. I can clearly see lacking. Frist, I thought it's the android problem then I download pdf and try it It's okay it runs smoothly.

Here my code

In the shared Project

   public class CustomWebView : WebView
{
 public static readonly BindableProperty UriProperty = BindableProperty.Create(nameof(Uri),typeof(string),typeof(CustomWebView),default(string));

 public string Uri
 {
    get => (string)GetValue(UriProperty);
    set => SetValue(UriProperty, value);
 }       

}
In anrioid Custom Render Like this

   public class CustomWebViewRenderer : WebViewRenderer
{
public CustomWebViewRenderer(Context context) : base(context)
{
}

 protected override void OnElementChanged(ElementChangedEventArgs<WebView> e)
{
    base.OnElementChanged(e);

    if (e.NewElement != null)
    {              
        Control.Settings.AllowUniversalAccessFromFileURLs = true;                   
        Control.Settings.BuiltInZoomControls = true;
        Control.Settings.DisplayZoomControls = true;

    }
    this.Control.SetBackgroundColor(Android.Graphics.Color.Transparent);
  }
  protected override void OnElementPropertyChanged(object sender, PropertyChangedEventArgs e)
  {
    if (e.PropertyName != "Uri") return;
    var customWebView = Element as CustomWebView;
    if (customWebView != null)
    {
        Control.LoadUrl(string.Format("file:///android_asset/pdfjs/web/viewer.html?file={0}", string.Format("file:///android_asset/Content/{0}", 
   WebUtility.UrlEncode(customWebView.Uri))));        
    }
 }

    }

It's getting the pdf and also it's showing without problem but when zoom in or out clearly can see the latching How to solve this latching problem.

The zoom in/out function in Webview is not smooth

Override iOS Accessibility setting for Bold Text

$
0
0

Is there a way to override the Bold Text setting under Accessibility in iOS? Some of our labels are getting truncated.

We have tried setting FontAttributes to None, but that did not make a difference.

Thanks

Failed to read FormsViewGroup.dll with debugging symbols

$
0
0

So... this error started popping up when I try building as Release on Android.

Failed to read 'C:\Users\gferreira\Documents\Source\Repos\EcoMindMobile\EcoMind\EcoMind.Android\obj\Release\81\linksrc\FormsViewGroup.dll' with debugging symbols. Retrying to load it without it. Error details are logged below.

The details:

1>Mono.Cecil.Cil.SymbolsNotMatchingException: Symbols were found but are not matching the assembly
1>   at Mono.Cecil.ModuleDefinition.ReadSymbols(ISymbolReader reader, Boolean throwIfSymbolsAreNotMaching)
1>   at Mono.Cecil.ModuleReader.ReadSymbols(ModuleDefinition module, ReaderParameters parameters)
1>   at Mono.Cecil.ModuleReader.CreateModule(Image image, ReaderParameters parameters)
1>   at Mono.Cecil.ModuleDefinition.ReadModule(Disposable`1 stream, String fileName, ReaderParameters parameters)
1>   at Mono.Cecil.ModuleDefinition.ReadModule(String fileName, ReaderParameters parameters)
1>   at Mono.Cecil.AssemblyDefinition.ReadAssembly(String fileName, ReaderParameters parameters)
1>   at Java.Interop.Tools.Cecil.DirectoryAssemblyResolver.ReadAssembly(String file)

This same error repeats 3 times throughout the build (found in the build log with Diagnostic MSBuild settings).

It seems to be something related to Xamarin Forms itself and linking, though after more hours than I'd like to admit sinked into this, I have no idea how to solve it. It's just warning, and it builds/works despite this, however just disregarding the warning doesn't seem like the best idea.

I didn't change anything in the release configs or nuget packages, it just started appearing out of the blue last week when I archived the solution.

The seemingly classic mscorlob conflict also appears, though this one has been happening for longer (I've been ignoring it as there doesn't seem to be an actual fix?)

1>There was a conflict between "mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" and "mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089".
1>    "mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" was chosen because it was primary and "mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" was not.

Could they be related? There are Xamarin.Forms references to both versions for some reason. Any ideas? I'm inclined to just start ignoring the warning, because so far things are still working.

Unable to deploy and install: Failed to parse APK file

$
0
0

Hi,

I have successfully updated an app from Xamarin.Forms v2 to version 4.5.
Unfortunately I am unable to install the app on the Android emulator, receiving the following error:

ADB0010: Mono.AndroidTools.InstallFailedException: Unexpected install output: Error: Failed to parse APK file: /data/local/tmp/com.myapp.name-Signed.apk

Exception occurred while executing:
java.lang.IllegalArgumentException: Error: Failed to parse APK file: /data/local/tmp/com.myapp.name-Signed.apk
    at com.android.server.pm.PackageManagerShellCommand.setParamsSize(PackageManagerShellCommand.java:338)
    at com.android.server.pm.PackageManagerShellCommand.runInstall(PackageManagerShellCommand.java:906)
    at com.android.server.pm.PackageManagerShellCommand.onCommand(PackageManagerShellCommand.java:158)
    at android.os.ShellCommand.exec(ShellCommand.java:103)
    at com.android.server.pm.PackageManagerService.onShellCommand(PackageManagerService.java:21328)
    at android.os.Binder.shellCommand(Binder.java:634)
    at android.os.Binder.onTransact(Binder.java:532)
    at android.content.pm.IPackageManager$Stub.onTransact(IPackageManager.java:2821)
    at com.android.server.pm.PackageManagerService.onTransact(PackageManagerService.java:3856)
    at android.os.Binder.execTransact(Binder.java:731)
Caused by: android.content.pm.PackageParser$PackageParserException: Failed to parse /data/local/tmp/com.myapp.name-Signed.apk
    at android.content.pm.PackageParser.parseApkLiteInner(PackageParser.java:1590)
    at android.content.pm.PackageParser.parseApkLite(PackageParser.java:1575)
    at com.android.server.pm.PackageManagerShellCommand.setParamsSize(PackageManagerShellCommand.java:331)
    ... 9 more

   at Mono.AndroidTools.Internal.AdbOutputParsing.CheckInstallSuccess(String output, String packageName) in E:\A\_work\548\s\External\androidtools\Mono.AndroidTools\Internal\AdbOutputParsing.cs:line 345
   at Mono.AndroidTools.AndroidDevice.<>c__DisplayClass95_0.<InstallPackage>b__0(Task`1 t) in E:\A\_work\548\s\External\androidtools\Mono.AndroidTools\AndroidDevice.cs:line 753
   at System.Threading.Tasks.ContinuationTaskFromResultTask`1.InnerInvoke()
   at System.Threading.Tasks.Task.Execute()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at AndroidDeviceExtensions.<PushAndInstallPackage>d__11.MoveNext() in E:\A\_work\548\s\External\androidtools\Xamarin.AndroidTools\Devices\AndroidDeviceExtensions.cs:line 187
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at AndroidDeviceExtensions.<PushAndInstallPackage>d__11.MoveNext() in E:\A\_work\548\s\External\androidtools\Xamarin.AndroidTools\Devices\AndroidDeviceExtensions.cs:line 203
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
   at Xamarin.AndroidTools.AndroidDeploySession.<InstallPackage>d__112.MoveNext() in E:\A\_work\548\s\External\androidtools\Xamarin.AndroidTools\Sessions\AndroidDeploySession.cs:line 433
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
   at Xamarin.AndroidTools.AndroidDeploySession.<RunAsync>d__106.MoveNext() in E:\A\_work\548\s\External\androidtools\Xamarin.AndroidTools\Sessions\AndroidDeploySession.cs:line 217
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Xamarin.AndroidTools.AndroidDeploySession.<RunLoggedAsync>d__104.MoveNext() in E:\A\_work\548\s\External\androidtools\Xamarin.AndroidTools\Sessions\AndroidDeploySession.cs:line 119  

I tried installing the apk using adb, but it fails again with the following message:

adb install .\com.myapp.name-Signed.apk
Performing Streamed Install
adb: failed to install .\com.myapp.name-Signed.apk: Failure [INSTALL_PARSE_FAILED_NOT_APK: Failed to parse /d
ata/app/vmdl581776687.tmp/base.apk]

I can run the iOS version, buit Android required much more package updates.

The app manifest is as follows:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.myapp.name" android:versionCode="51" android:versionName="2.6" android:installLocation="auto">
    <uses-sdk android:minSdkVersion="22" android:targetSdkVersion="29" />
    <uses-permission android:name="com.android.vending.BILLING" />
    <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
    <application android:label="APPNAME" android:icon="@drawable/icon" android:theme="@style/MyTheme">
        <meta-data android:name="android.max_aspect" android:value="2.1" />
        <provider android:name="androidx.core.content.FileProvider" android:authorities="com.myapp.name" android:exported="false" android:grantUriPermissions="true">
            <meta-data android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/provider_paths" />
        </provider>
    </application>
</manifest>

I am building the app using Visual Studio 2019, compiled using Android 10 (api 29).
I tried millions time to clean the project and rebuild but the output stays the same.

The apk contains:

  • assemblies
  • assets
  • lib
  • META-INF
  • res
  • AndroidManifest.xml
  • classes.dex
  • NOTICE
  • resources.asrc

I can browse the apk file using 7zip but it fails to unzip the package. So does win default zip, which leads me to think the Xamarin generates a corrupted file for some reasons.

My signature fields in the app properties are empty, but I am building in debug mode, which as far as I remember from native development will use a default key.

I have been struggling with this since days now. Did anyone had the same issue or can point me in the right direction?

Thanks in advance!

QueryProperty set being called after OnAppearing

$
0
0

Hello, I have a Shell application and am calling a page using "await Shell.Current.GoToAsync("//page?Id=1");" I have a string property and defined the QueryProperty attribute on my Page class. I have code in the OnAppearing that uses the id to get data from the database. However, the property setter isn't being called until after the OnAppearing event executes so the value is incorrect. Any ideas what I could be doing wrong?

Unable to use Permissions in Xamarin.Essentials

$
0
0

As detailed in Xamarin.Essentials: Permissions, the following code is giving an error that 'Permissions' is inaccessible due to its protection level.

            var status = await Permissions.CheckStatusAsync<Permissions.LocationWhenInUse>();

How do I proceed?

Binding issue in UWP project of an Xamarin.Forms app

$
0
0

My ItemsVM is:

    public class ItemsVM : BaseViewModel
    {
        public ObservableCollection<Item> Items { get; set; }
        … … ...
    }

Binding in a ContentPage is done as follows:

    public partial class MyPage : ContentPage
    {
        pageItemsVM ItemsVM;

        public MyPage()
        {
            InitializeComponent();

            BindingContext = pageItemsVM = new ItemsVM();
        }

        … … ...
    }

Bindings to ListView are as follows:

<ListView ItemsSource="{Binding Items}">
    … … …
                                            <StackLayout Margin="-2,10,-2,0"
                                                         BackgroundColor="{Binding Path=., Converter={StaticResource ConvertItemType2ColorBg}}"
                                                         HorizontalOptions="FillAndExpand">
                                               … … ...
                                            </StackLayout>
    … … ...
</ListView>

The converter code is:

    public class ConvertItemType2ColorBg: IValueConverter
    {
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            Item item = (Item)value;
            Color bgColor = Color.LightGreen;

            … … ...
            return bgColor;
        }

        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            throw new NotImplementedException();
        }
    }

In Android & iOS, in converter the value could be cast to Item. But in UWP the value passed is of type ItemsVM and not Item.

The page is bound to ItemsVM and the ListView is bound to ItemsVM.Items. Then the row should be bound to Item. Then how can this happen? How do I resolve it?


Svg image using FFImageloader

$
0
0

Hello, i am using the library above for displaying an svg image. Documentation code is the below :smile:

    <?xml version="1.0" encoding="UTF-8"?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" x:Class="FFImageLoading.Forms.Sample.SvgSamplePage"
        xmlns:ffimageloadingsvg="clr-namespace:FFImageLoading.Svg.Forms;assembly=FFImageLoading.Svg.Forms">

    <ContentPage.Content>
        <ffimageloadingsvg:SvgCachedImage WidthRequest="200" HeightRequest="200" Source="sample.svg"/>  

        <!-- SECOND APPROACH (PCL EmbeddedResource): -->
        <ffimageloadingsvg:SvgCachedImage WidthRequest="200" HeightRequest="200" Source="resource://FFImageLoading.Forms.Sample.Resources.sample.svg"/>  

    </ContentPage.Content>
</ContentPage>

My problem is that ffimageloadingsvg:SvgCachedImage doesnt exist. Propably SvgCachedImage class has been changed. Is there anyone who had the same issue?

Question about Xaml- ContentPage attributes

$
0
0

This is the auto generated code when you create a default content page

<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
            xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
            xmlns:d="http://xamarin.com/schemas/2014/forms/design"
            xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
            mc:Ignorable="d"
            x:Class="Namespace.Folder.MyClass">
</ContentPage>

What is the purpose of the next 3 lines of code? If I remove them, nothing seems to be effected...
Are they somehow important or can I remove them permanently?

xmlns:d="http://xamarin.com/schemas/2014/forms/design"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"

The previous versions of Xamarin did not had them...

Sqlite net multi tables

$
0
0

Hi,
I have some problems with the relations between my 3 tables. The 1 is "StatsEx" many to one => "Ex" many to many with "Trains". My table "Ex" is filled when the app is launch. But during the user utilisation, I would like to create new StateEx or Trains and update only the link with my table Ex.
Can you help me ? Because I don't know how to do it without update also my all table Ex.
Quent.

FFImageLoading Android 4.2 Not Show

$
0
0

hi
4.2 or 4.3 Not Show

not showing Source
show LoadingPlaceholder or ErrorPlaceholder

Boot completed in Xamarin Forms

$
0
0

I'm using the BOOT_COMPLETED intent in Xamarin.Android to allow my notifications to "survive" a reboot.

I'm planning on rewriting my app to Xamarin.Forms and am wondering how I can use the same workflow in Xamarin.Forms.

Anyone have experience with this?

How to add event to phone calendar in xamarin forms

$
0
0
I could not find any piece of code to add event in phone calendar. I am getting code only for xamarin.Android which am finding difficult to understand. Can anyone help platform dependency code for this?

Scenario:
I have a Ui which accepts date and time. On click of a button, i need to add an event to phone calendar

Navigation from Login Page to Main Page (TabbedPage)

$
0
0

Hi Community,
I am really new in Xamarin and the whole dev-world.
I want to start with a Login-Page, after successfull login it goes to the Main Page, which should be tabbed with Navigation so I can select between different other tabs.

I have the problem that the Navigation at the top appear twice. The Logout button too.

Login.xaml.cs contains:
Navigation.InsertPageBefore(new MainPage(), this);
await Navigation.PopAsync();

App.xaml.cs:

And the MainPage.xaml.cs:

What have I done wrong?
Thanks
riddler


Why does the Xamarin Form frame not match the device resolution

$
0
0

This question is specific to Xamarin forms running on an Android tablet.

I have a device with a screen resolution of 1280x800. A call to Xamarin.Essentials.DeviceDisplay.MainDisplayInfo confirms this, however the width and height passed in the Xamarin forms page OnSizeAllocated is different. The end result is that the screens layouts do not show as anticipated for the device resolution.

For example, the below code (in the code behind) provides the following values:
widthx=1280 (From Essentials)
heightx=800 (From Essentials)
width=961.50229575812
height=600.938934848825

protected override void OnSizeAllocated(double width, double height)
    {
        base.OnSizeAllocated(width, height);

        var mainDisplayInfo = DeviceDisplay.MainDisplayInfo;
        // Width (in pixels)
        var widthx = mainDisplayInfo.Width;
        // Height (in pixels)
        var heightx = mainDisplayInfo.Height;
        // Screen density
        var densityx = mainDisplayInfo.Density;            
    }

I have seen this behavior before, but only when changing the Android screen Zoom setting, in my case the Zoom level is set for no Zoom. There are no screen accessibility settings enabled.
I tried this on several new Samsung tablets with similar result, however on one of my older Samsung tablets the values matched as expected. Also, some emulators have results where the values match (as expected) and some emulators have the same behavior I am seeing here.

Anyone have any ideas why I am seeing this seemingly random and unpredictable behavior?

Slow page rendering

$
0
0

I have a list view, when item is selected my app is pushing a new page.

Howewer the render of this page is slow. Specially for the first item select. I tried to implement a progress dialog but it still slow. I tried with ACR USER DIALOGS OR an Activity indicator but Activity indicator isn't show at all, and ACR User dialogs is show but with delay and when the page is already loaded.

For example the delay between selected item click and the page display is 4 second delay, it is also slow to set the selected background item color.

`private async void DocumentListView_SelectionChanging(object sender, Syncfusion.ListView.XForms.ItemSelectionChangingEventArgs e)
    {
        UserDialogs.Instance.ShowLoading("Loading ...", MaskType.Black);
        try
        {
            if (e.AddedItems == null)
            {
                return;
            }

            var file = (FileModel)e.AddedItems[0];

            await Navigation.PushAsync(new PdfViewer(file.FilePath));
        }
        finally
        {
            UserDialogs.Instance.HideLoading();
        }
    }`

In this example I use syncfusion list view but I also tried with collection view and it is exactly the same thing.

How to get a flyout screen similar to Outlook ios app

$
0
0

Hi,
I am just starting with Xamarin app development and have been reading through the docs.
I am trying to get my head around a UI screen similar to Outlook Flyout screen in ios app.
Can some one point me in the direction of what can be base layout (is it Shell) and how are icons lineup on left portion and mailbox folders on the right side. I think I am overwhelmed with all layouts and views etc.

Thanks in advance

Forms 4.6.0.726: PR 10253 still causing problems

$
0
0

Hi,

I just upgraded to Forms 4.6.0.726 and I get this error in iOS. Android works fine. I don't see anything wrong with the code, what changed in 4.6 that could cause this?

If I comment out line 28: resultsTab.Items.Clear() then I get no error. Does the new PR https://github.com/xamarin/Xamarin.Forms/pull/10253 expect a different use case?

Test solution is attached.

> System.NullReferenceException: Object reference not set to an instance of an object
>   at Xamarin.Forms.Platform.iOS.ShellSectionRootRenderer.OnShellSectionPropertyChanged (System.Object sender, System.ComponentModel.PropertyChangedEventArgs e) [0x001b6] in D:\a\1\s\Xamarin.Forms.Platform.iOS\Renderers\ShellSectionRootRenderer.cs:261
>   at at (wrapper delegate-invoke) <Module>.invoke_void_object_PropertyChangedEventArgs(object,System.ComponentModel.PropertyChangedEventArgs)
>   at Xamarin.Forms.BindableObject.OnPropertyChanged (System.String propertyName) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\BindableObject.cs:229
>   at Xamarin.Forms.Element.OnPropertyChanged (System.String propertyName) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\Element.cs:353
>   at Xamarin.Forms.BaseShellItem.OnPropertyChanged (System.String propertyName) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\Shell\BaseShellItem.cs:210
>   at Xamarin.Forms.BindableObject.SetValueActual (Xamarin.Forms.BindableProperty property, Xamarin.Forms.BindableObject+BindablePropertyContext context, System.Object value, System.Boolean currentlyApplying, Xamarin.Forms.Internals.SetValueFlags attributes, System.Boolean silent) [0x00114] in D:\a\1\s\Xamarin.Forms.Core\BindableObject.cs:461
>   at Xamarin.Forms.BindableObject.SetValueCore (Xamarin.Forms.BindableProperty property, System.Object value, Xamarin.Forms.Internals.SetValueFlags attributes, Xamarin.Forms.BindableObject+SetValuePrivateFlags privateAttributes) [0x00173] in D:\a\1\s\Xamarin.Forms.Core\BindableObject.cs:397
>   at Xamarin.Forms.BindableObject.SetValueCore (Xamarin.Forms.BindableProperty property, System.Object value, Xamarin.Forms.Internals.SetValueFlags attributes) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\BindableObject.cs:343
>   at Xamarin.Forms.Element.SetValueFromRenderer (Xamarin.Forms.BindableProperty property, System.Object value) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\Element.cs:250
>   at Xamarin.Forms.ShellSection.OnChildAdded (Xamarin.Forms.Element child) [0x0001d] in D:\a\1\s\Xamarin.Forms.Core\Shell\ShellSection.cs:521
>   at Xamarin.Forms.ShellSection.ItemsCollectionChanged (System.Object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x00022] in D:\a\1\s\Xamarin.Forms.Core\Shell\ShellSection.cs:843
>   at Xamarin.Forms.ShellContentCollection.InnerCollectionChanged (System.Object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x0006f] in D:\a\1\s\Xamarin.Forms.Core\Shell\ShellContentCollection.cs:74
>   at System.Collections.ObjectModel.ObservableCollection`1[T].OnCollectionChanged (System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x00018] in /Library/Frameworks/Xamarin.iOS.framework/Versions/Current/src/Xamarin.iOS/external/corefx/src/System.ObjectModel/src/System/Collections/ObjectModel/ObservableCollection.cs:263
>   at System.Collections.ObjectModel.ObservableCollection`1[T].OnCollectionChanged (System.Collections.Specialized.NotifyCollectionChangedAction action, System.Object item, System.Int32 index) [0x00000] in /Library/Frameworks/Xamarin.iOS.framework/Versions/Current/src/Xamarin.iOS/external/corefx/src/System.ObjectModel/src/System/Collections/ObjectModel/ObservableCollection.cs:338
>   at System.Collections.ObjectModel.ObservableCollection`1[T].InsertItem (System.Int32 index, T item) [0x0001a] in /Library/Frameworks/Xamarin.iOS.framework/Versions/Current/src/Xamarin.iOS/external/corefx/src/System.ObjectModel/src/System/Collections/ObjectModel/ObservableCollection.cs:196
>   at System.Collections.ObjectModel.Collection`1[T].Add (T item) [0x00020] in /Library/Frameworks/Xamarin.iOS.framework/Versions/Current/src/Xamarin.iOS/external/corefx/src/Common/src/CoreLib/System/Collections/ObjectModel/Collection.cs:71
>   at Xamarin.Forms.ShellContentCollection.Add (Xamarin.Forms.ShellContent item) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\Shell\ShellContentCollection.cs:141
>   at PickerTestApp.AppShell+<>c__DisplayClass1_0.<RefreshAccountListAsync>b__0 () [0x000a6] in /Users/user171157/Downloads/PickerTestApp/PickerTestApp/AppShell.xaml.cs:46
>   at Foundation.NSAsyncActionDispatcher.Apply () [0x00000] in /Library/Frameworks/Xamarin.iOS.framework/Versions/13.16.0.13/src/Xamarin.iOS/Foundation/NSAction.cs:152
>   at at (wrapper managed-to-native) UIKit.UIApplication.UIApplicationMain(int,string[],intptr,intptr)
>   at UIKit.UIApplication.Main (System.String[] args, System.IntPtr principal, System.IntPtr delegate) [0x00005] in /Library/Frameworks/Xamarin.iOS.framework/Versions/13.16.0.13/src/Xamarin.iOS/UIKit/UIApplication.cs:86
>   at UIKit.UIApplication.Main (System.String[] args, System.String principalClassName, System.String delegateClassName) [0x0000e] in /Library/Frameworks/Xamarin.iOS.framework/Versions/13.16.0.13/src/Xamarin.iOS/UIKit/UIApplication.cs:65
>   at UIKit.UIApplication.Main (System.String[] args, System.Type principalClass, System.Type delegateClass) [0x00000] in /Library/Frameworks/Xamarin.iOS.framework/Versions/13.16.0.13/src/Xamarin.iOS/UIKit/UIApplication.cs:75
>   at PickerTestApp.iOS.Application.Main (System.String[] args) [0x00001] in /Users/user171157/Downloads/PickerTestApp/PickerTestApp.iOS/Main.cs:17

How to pass values from custom PageRenderer to Shared Xaml Page code behind in Xamarin forms.

$
0
0

How to pass values from custom PageRenderer to Shared Xaml Page code behind in Xamarin forms.

Viewing all 77050 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>