Hello everyone!
I am currently working with Xamarin.Forms and I am trying to create a custom PageRenderer for Android which would display a stream from the camera. In every example I have met, the custom view was created thanks to a layout axml file located in Resources\layout that was called thanks to the command view = activity.LayoutInflater.Inflate (Resource.Layout.CameraLayout, this, false);
such as in this example, which I am trying to replicate.
The problem is that Visual Studio does not display the subfolder layout inside Resources (the only subfolder shown is drawable). I tried navigating there and creating manually CameraLayout.axml but my program still refused to build when I called view = activity.LayoutInflater.Inflate (Resource.Layout.CameraLayout, this, false);
explaining that "Resources.Layout contains no definition for CameraLayout". The strange thing is that when I work on another application developed with Xamarin (not Xamarin.Forms), that folder is shown and I face no problem when building the application.
Has anyone faced that problem before? If yes, how did you create your custom Android view?
I am quite new to Xamarin and Xamarin.Forms so there might be something obvious I have missed. I am working with Visual Studio 2015 on Windows 7.
Thank you kindly to anyone who will take the time to answer.
Maxime Larcher