xamarin.android - Xamarin Forms image not showing-Android -


i have xamarin forms android app , when i'm using following code

 var image = new image { source = "lock.png" }; 

to show image, image isn't showing though.

and try change source icon.png (the default xamarin icon) , working fine.

does know how make image show in app?

(ps: image path : ".\myapp.droid\resources\drawable\lock.png".)

make sure image has build action set "android resource". otherwise, not copied final package , there no image app show. described in guide here: https://developer.xamarin.com/guides/xamarin-forms/working-with/images/#local_images


Comments

Popular posts from this blog

scala - 'wrong top statement declaration' when using slick in IntelliJ -

c# - DevExpress.Wpf.Grid.InfiniteGridSizeException was unhandled -

PySide and Qt Properties: Connecting signals from Python to QML -