xamarin.forms

xamarin forms get pdf path

我们两清 提交于 2020-04-30 16:35:55
问题 I've successfully read a pdf from the project and displayed in a WebView. What I want to do is to get the pdf file path from my project and check if it exists to display it, and if not, to give it another URI to open with. Anyone knows how I can get the path of the pdf and it works for both Android and iOS. Here is my C# code: string internalstorageurl = string.Format("file:///android_asset/Content/{0}", WebUtility.UrlEncode("Conctionprofile.pdf")); public pdfviewer () { InitializeComponent (

xamarin forms get pdf path

给你一囗甜甜゛ 提交于 2020-04-30 16:35:54
问题 I've successfully read a pdf from the project and displayed in a WebView. What I want to do is to get the pdf file path from my project and check if it exists to display it, and if not, to give it another URI to open with. Anyone knows how I can get the path of the pdf and it works for both Android and iOS. Here is my C# code: string internalstorageurl = string.Format("file:///android_asset/Content/{0}", WebUtility.UrlEncode("Conctionprofile.pdf")); public pdfviewer () { InitializeComponent (

Error: Unable to generate deps.json, it may have been already generated. when adding a Service reference to Xamarin forms

匆匆过客 提交于 2020-04-30 12:32:31
问题 i have a Xamarin forms v3.1 project with the .net standard approach, i try to add a reference to a web service i have using add connected service and then from the pop up i choose microsoft web service reference provider. i add the web service link and visual studio (2017 v15.8) discovers its structure then when i click finish it takes a while then shows this error: Unable to generate deps.json, it may have been already generated. You can specify the "-d" option before the tool name for

Scrollview is not working in Xamarin Forms

你离开我真会死。 提交于 2020-04-30 10:42:25
问题 I have following layout in my xamarin forms application: <?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:telerikInput="clr-namespace:Telerik.XamarinForms.Input;assembly=Telerik.XamarinForms.Input" xmlns:telerikPrimitives="clr-namespace:Telerik.XamarinForms.Primitives;assembly=Telerik.XamarinForms.Primitives" x:Class="DMGMobile.UserDetailPage"> <ContentPage.ToolbarItems> <ToolbarItem

Scrollview is not working in Xamarin Forms

谁都会走 提交于 2020-04-30 10:38:19
问题 I have following layout in my xamarin forms application: <?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:telerikInput="clr-namespace:Telerik.XamarinForms.Input;assembly=Telerik.XamarinForms.Input" xmlns:telerikPrimitives="clr-namespace:Telerik.XamarinForms.Primitives;assembly=Telerik.XamarinForms.Primitives" x:Class="DMGMobile.UserDetailPage"> <ContentPage.ToolbarItems> <ToolbarItem

Scrollview is not working in Xamarin Forms

╄→尐↘猪︶ㄣ 提交于 2020-04-30 10:38:02
问题 I have following layout in my xamarin forms application: <?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:telerikInput="clr-namespace:Telerik.XamarinForms.Input;assembly=Telerik.XamarinForms.Input" xmlns:telerikPrimitives="clr-namespace:Telerik.XamarinForms.Primitives;assembly=Telerik.XamarinForms.Primitives" x:Class="DMGMobile.UserDetailPage"> <ContentPage.ToolbarItems> <ToolbarItem

Dynamic intervals in SetRepeating() method Android [Xamarin.Forms]

只谈情不闲聊 提交于 2020-04-30 07:01:05
问题 I have been seeking in forums to how to implement dynamic intervals on repeated notifications but I haven't found yet a precise answer or a "common" answer for this type of problem. My problem consist that I want to set dynamic intervals (intervals that change when the past interval has gone to be used) on my AlarmManager.SetRepeating() parameter, but as you should know SetRepeating() interval parameter is constant, so you can't change it later to other beacuse the method has already recieved

How to bind and get word of resx (localization)

旧城冷巷雨未停 提交于 2020-04-30 06:30:17
问题 I followed this article: https://docs.microsoft.com/en-us/xamarin/xamarin-forms/app-fundamentals/localization/text?pivots=macos I want to bind and get a value of my .resx Title="{x:Static resx:AppResources.Binding Title}"> their value of title is Road, Fly, Run from my ViewModel <data name="Road" xml:space="preserve"> <value>Camino</value> </data> 回答1: I have checked that in local site as follow steps , and it works . Creat a AppResources.resx file : <data name="Fly" xml:space="preserve">

ToolbarItems do not look right in iOS

六月ゝ 毕业季﹏ 提交于 2020-04-30 06:27:27
问题 I have a Xamarin.Forms app with FreshMvvm, and am trying to use secondary ToolbarItems. Here is a part of my PageModel code: public override void Init(object initData) { CurrentPage.ToolbarItems.Add(new ToolbarItem() { Text = "About LATICRETE", Command = AboutCommand, Priority = 0, Order = ToolbarItemOrder.Secondary }); CurrentPage.ToolbarItems.Add(new ToolbarItem() { Text = "Call LATICRETE", Command = CallCommand, Priority = 0, Order = ToolbarItemOrder.Secondary }); CurrentPage.ToolbarItems

How to give unique id for each button

一世执手 提交于 2020-04-28 21:50:23
问题 I have buttons created by loop and each button it corresponds to a desk, so i have to able when i click a button i have to design spesific row of database how i add buttons: for (int i = 1; i < terasmasasayisi; i++) { var buttonteras = new Button { Text = i.ToString(), HeightRequest = 45, WidthRequest = 45, Margin = 5, BorderRadius = 100, };`` teras.Children.Add(button); } If i can set a relationship between the table number and i(desknumber), I can do this according to the id from my