Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

where to put images for xamarin forms application

I am developing an application for Android, iOS and Visual Studio using Xamarin

I added the following lines in xaml to use images:

<Image Source="header.png" Grid.Row="0" Grid.Column="0" Grid.ColumnSpan="2" />
<Button x:Name="Object_Detection" Image="header.png" />

The first is for displaying an image in the header and the second is for displaying a button icon. They link for the same image "header.png"

I put the image under: - Mobile.Droid\Resources\drawable - Mobile.iOS\Resources -Mobile.Windows\Assets

But the image is not shown at all in the Windows 8.1 app. the image size is 690*79.

how to resolve the problem?

like image 515
ProEns08 Avatar asked Mar 12 '23 05:03

ProEns08


1 Answers

You have to place images in the root Project directory for Windows Phone 8, Windows Phone 8.1 and UWP applications.

This guide will help you http://developer.xamarin.com/guides/xamarin-forms/working-with/images

like image 97
Abdul Muhaymin Avatar answered Mar 14 '23 19:03

Abdul Muhaymin