I'm using Mono for Android 4.2.4 with VS 2010. The layout designer does not refresh properly if you change the theme, API version, orientation or device name from the designer toolbar. MonoDevelop works fine.
Is there a resolution for this?
I have not seen one. There are other issues as well, if you modify a xaml file and change widows without saving it, your changes will disappear! While Monodroid is an awesome tool, there are still a few bugs
Related
I'm aware that when developing in Xamarin.Forms I have available some tools for hot reloading, such as:
https://github.com/AndreiMisiukevich/HotReload
https://marketplace.visualstudio.com/items?itemName=Xamarin.XamarinLiveReload
https://www.livexaml.com/
However I wasn't able to find an equivalent alternative for Xamarin.Android. Is there an alternative out there that I can use for hot reloading on Xamarin.Android?
There's two ways of creating a layout in Xamarin Android:
Using axml layouts - If you upgrade to the latest Xamarin & Visual Studio on a Mac, you will notice that the designer view for a layout gets updated in real time with the axml code. So technically it's live reloading.
Inside the fragment(CS file) - For this you can use Continuous, as you can see it in use here. Ryan Davis is available on Twitter, and he's pretty quick to respond
I started using Visual Studio 2017 Enterprise Edition with Version 15.7.4. and Xamarin Version 4.10.0 and need to work on Xamarin native android application.
But Auto fill suggestions not coming in xml and axml files. Intellisense working for widget names(Like TextView, EditText etc.) In layout axml files. But, for widget properties (Like android:layout_width, android:gravity etc.) it isn't working. Where as in styles.xml, menu.xml suggestions not coming at all. I check with following ways.
1) XML - Schemas > android-layout-xml.xsd and schemas.android.com.apk.res.android.xsd files are exists
2) File opened as XML (Text) Editor
3) I didn't find Resharper in Tools
Also, Is there any way to change Xamarin keyboard shortcuts to Android Studio or Eclipse?
Being a Xamarin developer for almost two years I have come to terms with the fact that the Xamarin Android intellisense has never worked as it is expected.
It has a lot of bugs and issues (Links below) which have made it a real pain in the neck, But there are workarounds which you have already mentioned above and if those do not work for you trust me nothing will.
https://forums.xamarin.com/discussion/118384/android-designer-does-not-work-well
https://forums.xamarin.com/discussion/125879/designer-not-loading-layout-at-all
https://forums.xamarin.com/discussion/76851/visual-studio-2015-android-designer-not-working
https://forums.xamarin.com/discussion/82082/android-designer-not-working-in-visual-studio-enterprise-2015
https://forums.xamarin.com/discussion/6258/android-designer-doesnt-work-in-vs-2012
https://developercommunity.visualstudio.com/content/problem/99268/xamarin-android-designer-not-working.html
My suggestions:
Android studio provides you with a very strong designer and hence I would simply suggest you use Android studio to write down your XML and then just copy paste it to your Xamarin AXML/XML files and it should work like a charm, Same can be done for any other time of files such as strings or styles XML.
For changing the visual studio shortcuts you can simply check the following guide
When opening the Android UI Designer in Visual Studio Enterprise 2017 it does not render the view correctly. It only looks like this:
The view is correctly displayed in Xamarin Studio on my colleagues' PCs and is rather simple. I even tried starting a new sample project in VS. Same problem there.
Anybody has an idea how to fix this?
Visual Studio usually struggles in designer, especially when there are loads of features or complex resources etc. Best method is to just ignore the designer and always use code view. Alternatively Android studio has a good designer if it is a necessity.
Hope i could help.
I am very new to android apps, I do mostly VS2013, and I was just trying to do a hello world or anything basic. Why is there a tiny "hello world" on my design for my .xml file, but the button I added shows on the AVD? I'm really confused.
EDIT: To clarify, this is a brand new project. My question specifically is how can I make sure I can see on the design/text tabs what is going to be on my emulator? All I have done is drag/drop from the Palette onto the screen,and see nothing. What should I be doing instead?
The design device is the same as my AVD.
All: The solution was an issue with the rending, and is apparently a bug with the newest version of the Studio. This link I found had the information and solutions to help me with it:
Rendering problems in Android Studio v 1.1 / 1.2
I installed Mono for Android with the intention of using Visual Studio 2010 to design android apps. I am able to compile and deploy applications, but I am not able to view the layout designer. When I double click on an .axml file it opens in source view and there is no context menu option such as "View in designer." I am able to use MonoDevelop to create the layout, but I shouldn't have to do that.
Here are some screen caps:
Any tips?
It seems to simple but right clicking on the Main.axml in Visual Studio and select and choose Open with. Then select Android Designer should do the trick.
Despite that Android Designer can be set as Default it appears not to be working like that. I should say that's a BUG in VS and/or Monofor Android.
Are you shure to have the latest Mono for Android installed? (Version 4.2.4)
The Open With Dialog should have an entry "Android Designer".
Select this now and click "Set as Default".
Did a full uninstall, reinstall and reboot.
At first it didn't seem to have fixed it - my existing hello world project still wouldn't open the designer.
I tried creating a new project and ta-da all good now! Very odd.
I've very pleased to have gui designer. It really helps level the learning curve when learning a new platform - nice work Xamarin.
I did 3 installs until it finally took. I uninstalled then reinstalled and it still didn't work. I then just did a repair and it finally worked. Just keep reinstalling and you'll get it.