i have list view with labels and checkboxes and a button at bottom of page . so when i click button i want to get data of checkbox in checked state .
How can i do that.
I am using web api to fetch data from database and display it in label .
i have list view with labels and checkboxes and a button at bottom of page . so when i click button i want to get data of checkbox in checked state .
How can i do that.
I am using web api to fetch data from database and display it in label .
I have a StackLayout(View) inside of which I am having Image and Label aligned Horizontally (refer screenshot below). The Label should have a Marquee property. For that, we are using animation on the Label (using TranslateTo) and giving new X-position on tap gesture, when we click on the label the label starts moving right to left as Marquee, but it is overlapping the image. Is there any way to implement it in Xamarin.Forms IOS? so Marquee Label won't overlap the Image.
Hello people!
I wish to use some custom BindableObject derivations for setup in my views. As a part of this I wish to use DynamicResource. However, it seems to me like it is not able to find any resources.
I am setting the inherited binding context, but apparently - and, frankly, unsurprisingly - this is not enough.
Is it not possible to use DynamicResource on custom BindableObject types? If so, this is sad and I will have to find another way to do what I want.
Hi Guys,
I trying to implementing the deep-linking concept from Mail applications to Mobile application or Mobile site by referring the deep-linking concept from
https://www.xamboy.com/2019/01/08/applinks-in-xamarin-forms/
It's working fine if I'm testing through Deeplinknig Tester(ex:https:\test.com). But it's not working in my application via mail client(HTML file).
For Android, In MainActivity file, added the below code snippet,
[IntentFilter(new[] { Android.Content.Intent.ActionView }, DataScheme = "https", DataHost = Constants.DeepLinkURL, AutoVerify = false, DataPathPrefix = "/", Categories = new[] { Android.Content.Intent.CategoryDefault, Android.Content.Intent.CategoryBrowsable })]
My package name is "com.test.android"
Can you please suggest any ideas or the best way of implementing the deep linking concepts?
Hello,
In my app, I need to redirect users to the login page when they leave the app. Currently, I'm doing this via the OnSleep life-cycle event. On iOS, system dialogs trigger OnSleep. So when the TouchID/FaceID prompt shows, OnSleep is called. Also, when you call Device.OpenUri, OnSleep is triggered even though you remain in the app and only see a system dialog.
Is there a way I can detect if the app is still active and a system dialog is showing in OnSleep for iOS?
Thanks!
Hi everyone
Im looking for a free alternative to Sync-fusion for Xamarin forms. I have been looking for a while now and could only find a couple solutions on github. Any help will be greatly appreciated.
Can any one Please let me know how to do Download video or file with progress indication from app in xamarin forms ?
Please help me on this?
Thanks in advance.
I have some experience obfuscating Xamarin Android projects but I'm hitting a wall with Xamarin Forms. The linker does not accept the obfuscated DLL.
Has anyone gotten an obfuscator to work with Xamarin Forms? If so, which?
Thank you all.
Hi guys, I have been trying to do some navigation from native to forms and within forms.
From native to forms. I am doing SetPage(App.Newpage()) to reach the page, therefore can not use pushasync anywhere in the forms as it is not a navigation page anymore.
Within forms the workaround I did is that I used MessagingCenter to navigate from one page to another.
File DisplayResult:
On clicking the button I want this page to navigate to Main page.
private void Button_Clicked(object sender, EventArgs e)
{
MessagingCenter.Send (this, "Go Back");
}
In MainPage:
MessagingCenter.Subscribe(this, "Go Back", async (s) => await Navigation.PushAsync(new MainPage()));
Error: No view found for id 0x1 (unknown) for fragment FragmentContainer{44d7b27 #2 id=0x1}'
Any help would be appreciated. I have been pulling my hair from last 5 days.
I am developing a Xamarin app which retrives info from DB, take/choose photo and upload them to remote server, display this images from the remote server and the user can delete them by tap on and press a button. The final step is to download the images stored in the server to the local device gallery.
This is my current button click event:
private void button_download_image_Clicked(object sender, EventArgs e) { Uri image_url_format = new Uri(image_url); WebClient webClient = new WebClient(); try { webClient.DownloadDataAsync(image_url_format); webClient.DownloadDataCompleted += webClient_DownloadDataCompleted; } catch (Exception ex) { DisplayAlert("Error", ex.ToString(), "OK"); } }
Below the webClient_DownloadDataCompleted method:
private void webClient_DownloadDataCompleted(object sender, DownloadDataCompletedEventArgs e) { try { Uri image_url_format = new Uri(image_url); byte[] bytes_image = e.Result; Stream image_stream = new MemoryStream(bytes_image); string dest_folder= Android.OS.Environment.GetExternalStoragePublicDirectory(Android.OS.Environment.DirectoryDownloads).ToString(); string file_name= Path.GetFileName(image_url_format.LocalPath); string dest_path= Path.Combine(dest_folder, file_name); using (var fileStream = new FileStream(dest_path, FileMode.Create, FileAccess.Write)) { image_stream.CopyTo(fileStream); } DisplayAlert("Alert", "Download completed!", "OK"); } catch (Exception ex) { DisplayAlert("Error", ex.ToString(), "OK"); } }
But it does not work, no error caught, I get the alert which warn me that the download is completed. Also I gave permission for internet, write_external_storage and read_external_storage.
Another thing is that the images after some time, appears in the gallery under Download album which is correct.
Any idea about this behavior?
Firebase has made a solution for mobile phone authentication but there are no examples on how to implement it. I have managed to get email authentication working but nothing for Phone. I tried using the documentation for iOS and Android but I still cannot figure out how it should work.
https://firebase.google.com/docs/auth/android/phone-auth
This is what I'm trying to use for android. I made an interface in the shared folder, and a FirebaseAuthenticator in the android project, but the documentation for Android doesn't really help me. Does anyone have any idea or a working solution for Firebase.Auth for phone authentication?
Hi,
I have used Absolute Layout to design my screens but when I run it on different Android devices, ex: iBall Tab & Lyf Mobile the components positions shifts. Whereas on my Sony Z2 it shows perfectly. Any idea on what could be causing it ?
-Thanks
Mahesh
I tried to install the "Signature Pad" component, but when I tried to in Android this message pops:
Adding SignaturePad.Xamarin.Forms.PCL...
Attempting to resolve dependency 'Xamarin.Forms (≥ 1.5.1.6471)'.
Attempting to resolve dependency 'Xamarin.Android.Support.v4 (≥ 23.0.1.1)'.
Attempting to resolve dependency 'Xamarin.Android.Support.Design (≥ 23.0.1.1)'.
Attempting to resolve dependency 'Xamarin.Android.Support.v7.AppCompat (≥ 23.0.1.1)'.
Attempting to resolve dependency 'Xamarin.Android.Support.v7.CardView (≥ 23.0.1.1)'.
Attempting to resolve dependency 'Xamarin.Android.Support.v7.MediaRouter (≥ 23.0.1.1)'.
Adding 'Xamarin.Android.Support.v4 23.0.1.1' to Handwriting.Droid.
Could not install package 'Xamarin.Android.Support.v4 23.0.1.1'. You are trying to install this package into a project that targets 'MonoAndroid,Version=v2.3', but the package does not contain any assembly references or content files that are compatible with that framework. For more information, contact the package author.
I really need help, please. Thank you in advance.
So I have this weird problem that the following Code doesn't change the Placeholder color of the SearchBar:
<SearchBar x:Name="sbFeeding" HeightRequest="40" Placeholder="{translate:Translate SearchHereToFilter}" Margin="10,10,10,10" BackgroundColor="#578d76" CancelButtonColor="White" TextColor="White" Text="{Binding SearchText}" SearchCommand="{Binding SearchCommandFeeding}" PlaceholderColor="White"> <SearchBar.Behaviors> <viewmodels:FeedingTextChangedBehavior /> </SearchBar.Behaviors> </SearchBar>
But doing it from the Page itsself works:
protected override void OnAppearing() { sbFeeding.PlaceholderColor = Color.WhiteSmoke; base.OnAppearing(); }
Anyone able to see what I'm doing wrong here?
P.S.: I'm using Xamarin.Forms 4.3.0.991211 on Visual Studio 2019 16.3.10 on Windows
Hi Guys, I am trying to make a cross platform application with xamarin that gets the product informations(quantity,description,price,image) from an sql database. Is that possible and how ? Maybe i can get the data to a list in c# ?
Something must have changed recently in an update as I am no longer able to bypass certificate validation using the ServerCertificateValidationCallback delegate. Previously I had a build configuration that auto-enabled the "Managed" HttpClient implementation and a certificate callback so that we could use the 10.0.0.3 local address to talk to a local server for development purposes. This allowed us to use a local CA certificate that is not in Android emulator's trusted root.
It has been a little while since I needed to do this type of server side debugging so switching to the Local build configuration no longer seems to work. I never get to the callback and instead get a validation error. Anyone know if something specifically changed to be able to bypass the cert verification?
EXCEPTION:
Ssl error:1000007d:SSL routines:OPENSSL_internal:CERTIFICATE_VERIFY_FAILED
at /Users/builder/jenkins/workspace/archive-mono/2019-06/android/release/external/boringssl/ssl/handshake_client.c:1132
at Mono.Btls.MonoBtlsContext.ProcessHandshake () [0x00048] in <9e820d206a8d4177b453df9c2fa8d1cc>:0
at Mono.Net.Security.MobileAuthenticatedStream.ProcessHandshake (Mono.Net.Security.AsyncOperationStatus status, System.Boolean renegotiate) [0x000da] in <9e820d206a8d4177b453df9c2fa8d1cc>:0
at (wrapper remoting-invoke-with-check) Mono.Net.Security.MobileAuthenticatedStream.ProcessHandshake(Mono.Net.Security.AsyncOperationStatus,bool)
at Mono.Net.Security.AsyncHandshakeRequest.Run (Mono.Net.Security.AsyncOperationStatus status) [0x00006] in <9e820d206a8d4177b453df9c2fa8d1cc>:0
at Mono.Net.Security.AsyncProtocolRequest.ProcessOperation (System.Threading.CancellationToken cancellationToken) [0x000fc] in <9e820d206a8d4177b453df9c2fa8d1cc>:0
Local Build Config in Android Project:<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Local|AnyCPU'"> <DebugSymbols>true</DebugSymbols> <DebugType>full</DebugType> <Optimize>false</Optimize> <OutputPath>bin\Local</OutputPath> <DefineConstants>DEBUG;__LOCAL__;</DefineConstants> <ErrorReport>prompt</ErrorReport> <WarningLevel>4</WarningLevel> <AndroidLinkMode>None</AndroidLinkMode> <AndroidSupportedAbis /> <AndroidHttpClientHandlerType>System.Net.Http.HttpClientHandler</AndroidHttpClientHandlerType> <AndroidLinkTool>r8</AndroidLinkTool> <AndroidDexTool>d8</AndroidDexTool> <AndroidEnableMultiDex>false</AndroidEnableMultiDex> <AndroidEnableSGenConcurrent>true</AndroidEnableSGenConcurrent> <LangVersion>latest</LangVersion> <AndroidTlsProvider> </AndroidTlsProvider> </PropertyGroup>
MainActivity OnCreate:
//if __ LOCAL __
System.Net.ServicePointManager.ServerCertificateValidationCallback += (sender, cert, chain, sslPolicyErrors) => true;
//endif
I'm using embedded images for an app. They display fine but they seem to be quite small. When I originally created the same layout using a locally defined image resource, the image scaled correctly.
What am I missing? I've tried removing the use of PancakeView but that has made no difference.
<StackLayout VerticalOptions="StartAndExpand">
<pancakeView:PancakeView x:Name="DarkMapV" CornerRadius="30" HorizontalOptions="Center" VerticalOptions="StartAndExpand">
<Image Aspect="AspectFit" Source="{markupExtensions:ImageResource MyApp.Images.map1.png}" />
</pancakeView:PancakeView>
<pancakeView:PancakeView x:Name="LightMapV" CornerRadius="30" HorizontalOptions="Center" IsVisible="False" Opacity="0" VerticalOptions="StartAndExpand">
<Image Aspect="AspectFit" Source="{markupExtensions:ImageResource MyApp.Images.map.png}" />
</pancakeView:PancakeView>
</StackLayout>
I want to implement a login screen which accepts username,password.
If user wants to use fingerprint auth from next login(and if available), fingerprint authentication should happen. I am able to implement fingerprint auth, but not sure how to do it from second login.
What should be done here? Use dependency service?
I'm seeing an odd issue and running out of ideas.
This is only happening on two devices in our test pool currently (iPhone X and iPad Mini 4).
I've tried standard Image and CachedImage from ffimageloading.
When the app first loads, it checks if its a new user/first time in app. If true, it loads up an onboarding page. This is all pretty standard prism based mvvm etc (and works 100% on Android and every iOS simulator and most iOS devices).
The onboard has 3 images. The first time, its blank - like nothing loads (or perhaps is getting purged from memory?) If you reopen it manually, its fine. Images are there, so I know that device target build is getting the assets bundled properly.
I am currently deploying a new build that includes OneTime binding on the source and RetryCount + LoadingPriority.
Here's an example:
<ffi:CachedImage Grid.Row="0" HeightRequest="309" WidthRequest="364" Source="{Binding HelpSource}" AutomationProperties.IsInAccessibleTree="False" DownsampleToViewSize="True" Aspect="AspectFit" />