I'm working on an Xamarin project for school using C# on VS2019. I'm limited to only using Android. I've been using the built in Android Device manager within VS for my Android Emulator. Hot Reload has been working great up until now. For some reason, my XAML changes are no longer displaying on the emulator immediately using hot Reload.
In the output window, I'm seeing this error StopHotReload: Could not find project for MonoDevelop.Debugger.Soft.MonoDroid.MonoDroidDebuggerSession. I haven't made any changes to the solution or updated any packages. Any ideas why it would just randomly stop working?
It's now working for either mode Changes only(Xamarin.Forms 5.x and newer or Full Page
Related
I am making an android application on xamarin VS 2019.
I tried using different VS emulators. When I debug, the phone loads and I can rotate it but when I try to turn it on it does not work. It says that System UI won't turn on and at other times it says that the process failed. I cannot figure out why, I did exactly the same as the tutorial.
I'm working on a project with a friend, we are using git for version control. They created the unity project and I pulled it to my computer as well. Every time I open the project, I have 2 blank compiler errors. I cannot click on them to open VS because they seemingly do not exist.
I can confirm as well we are using the same unity version (2019.2.15f1) both on Windows machines (mine is Win10)
Here is a list of things I have tried as suggested by other forums and my teammate:
Deleting and recreating library folder (results varied from no effect to unity no longer launching)
Creating a new directory and launching a fresh version (worked correctly on their system, not mine)
Reinstalling Unity
Triple checking that my version is up to date
Reinstalling Unity and Visual Studio
Changing the scripting framework (suggestion was to downgrade from 4 to 3.5, we were already on 2 for some reason)
Edit: Here's a picture of the errors
Edit 2: Attempted to open new project in older version of unity, the following error appeared
Edit 3: Upgraded to Unity v 2020.1.0a14
Edit 4: Never mind, now it's not even letting me open the project anymore. Complete with a cool fun new error.
Edit 5: It just... started working. I reinstalled unity again and it just decided to work.
It seems that your project use some packages that aren't installed in your project.
Try to re import the packages mentioned in this image:
enter image description here
I created an app in Unity where you get a start screen with some GUI elements: a top bar with some title graphics and a scrollView with buttons that load dynamically using c# and xml that allow me to active canvases depending on the pressed button... this all works perfectly when I run it on pc but when I try to install it on android, it only shows the "Made with Unity" animation and loads the top bar and the background.. I just can't get any gamelogic to run..
I even forced the first level to run, and it switches canvas but nothing else, no sprites loaded into the GUI images, no listviews being populated, nothing..
I then tried to load a canvas that should be able to search for levels/chapters with an inputfield and then display all chapters that contain that text.. I can select the inputfield, the onscreen keyboard appears and I can type text, but again, the list isn't being populated..
I did have a lot of trouble getting the app to build (commandInvocationFailure, ..) and searched the web for every error I got and kept getting new errors untill I found a "sweet spot":
Unity 5.6
SDK that came with newest Android Studio
Downgraded tools in SDK to version 25.2.5
Had to copy zipalign.jar from build-tools to tools
downgraded JDK from 9.1 to 8.1
install location "automatic"
this allowed me to build my app but it's extremely fragile, one wrong setting and it won't build..
I'm trying to run the app on a Samsung Galaxy Tab4 (Android 5.1 Lollipop) I installed the proper API with SDK Manager but when I set the API level in Unity I can only select "highest installed" or it won't build. I tried installing on a Samsung Galaxy Tab A (Android Nougat) but there I get a "Not Installed" message.. (third party sources is checked)
The build itself is quite large (1.7gig but has over 3000images and sounds which I downsampled so all resources are around 500MB)
(the entire app is made out of GUI elements)
anyone who encountered this problem or can shed some light on what I'm doing wrong?
Found the answer: app depends heavily on xml and adressing an xml file on android is different than on a pc.. so app worked but couldn't find the xml so no data was loaded..
I am repeating a question posed on Xamarin forums by another user as there has been no solution (http://forums.xamarin.com/discussion/37139/debug-chaos). Since the update to Xamarin at the start of April.
I'm facing very strange debugging errors using Xamarin Studio.
1) Set a breakpoint in the IDE and it stops at the breakpoint with a nullreferenceexception, even when the breakpoint is set on a curly bracket of a function.
2) Move the breakpoint by 1 line and the nullreferenceexception will occur there instead.
I have tried to enable/disable fast deploy and mono shared runtime without changes, and fully reinstalled Xamarin Android and Xamarin Studio.
Any ideas? It's very frustrating to not be able to debug.
Update: Xamarin Studio v5.8.2, Xamarin.Android v4.20.0.37, Nexus 7 (2013) running Android 5.0.2
it is a related to drawable images problem, please do try it that remove image from layout file and then run application as same configure it will be run successfully.
this type of problem i face at staring but now i have the solution to how to handle it.
setting android images and icon is perfect hierarchy which is mention below images and also update your SDK.
I've develop a test application in Xamarin Studio (Android with C#) and wanted to test it on my phone.
The application worked just fine in the Device emulator (Same OS version) but when I install / open it on my phone, it just says "TestApplication stopped working" I know from the online search that thousands of issues could cause this error message but my questions is :
Is exporting my app on my droid as simple as :
Compiling the app
Taking the signed .apk in the .bin folder
Dragging that .apk on the phone (I'm using AirDroid to drag the file)
Running the .apk (installing the app)
Am I missing an obvious, magic step ?
I don't know how Xamarin Studio works, but this happened to me when trying the same, using Visual Studio.
I found out the application worked only when building in Release mode.
Not sure if Xamarin Studio has the same options (Debug / Release / etc)
I believe I'm a bit late here, but it seems time changed things.
What I had to do (and I can't seem to understand why it's not more intuitive than that) is to:
Right click on Solution
Archive
Follow the Wizard steps
Better instructions can be found here: https://learn.microsoft.com/pt-br/xamarin/android/deploy-test/signing/?tabs=windows