Im having serious problems with screen rotation in Windows Phone. The project Im currently working started in the WP 8.0 version. After the 8.1 release, I updated my VS 2013 to the 2nd update and I migrate my project to 8.1. My problems is that, when I try to use the command: “DisplayInformation.AutoRotationPreferences = DisplayOrientations.Landscape”, inside a click button event, the app running on my device (nokia lumia 920 with 8.1) does absolutely nothing.
I also tried to change the Supported Orientation Option in Package.appxmanifest but such option is not presented there! !
The weirdest thing is that everything works just fine (both code, and the appearance of the “Supported Orientation” option in the Package.appxmanifest) when I create from scratch a new project WP 8.1 project in visual Studio. I also noticed some other differences like the lack of wmappmanifest.xml on this scratch project.
Image comparing both projects
If you guys want to check the issue, download the google ad sample for WP, upgrade it to 8.1 and add the rotation code above. It will do nothing. If you create a new empty 8.1 project and do the same thing, everything works fine.
https://developers.google.com/mobile-ads-sdk/download#downloadwp
My question is, what the hell is going on with project migration? Is there anything I`m missing, so that the old project is no totally upgraded yet?
DisplayInformation.AutoRotationPreferences is for WP8.1 RT (RunTime) apps only. When your upgrade your existing WP8 app to WP8.1 it is still a WP silverlight app. Thats what the problem is. When you create a WP8.1 from scratch you are creating a WP8.1 RT app. So the code works.
Take a look at the MSDN reference on the bottom is states that the API is only for Win8.1 RT Apps
Related
I recently updated my machine from Windows 8 to Windows 10. Since then, I get a NullReferenceException in SharpDX.Toolkit.Game.dll when I call
this.game.Run(context)
Where game inherits from SharpDX.Toolkit.Game and context is a SharpDX.Toolkit.GameContext with a ContextType of DesktopWpf.
On the SharpDX Homepage I could not find any information about migrating projects to Windows 10.
Before upgrading, everything worked fine. Do I need to tweak any special setting? Or do I need to upgrade to SharpDX 3.0.0, which is still alpha?
Edit: The exception is not raised in my code, but in the code of SharpDX - just to make it clear.
I just found the solution:
After upgrading Windows from 8.1 to 10, you need to upgrade your Windows SDK as well by installing the Windows 10 SDK.
The Windows 10 SDK can be downloaded here.
We are evaluating Xamarin Forms for our next project to develop the same application for the three major platforms: Android, iOS and Windows Phone.
As we mostly work with WP and Windows apps within the company, we have a well working base setup for work environment. It consists of a Windows 8.1 Pro/Enterprise install, Visual Studio 2013 Update 4 with both WP 8.0 and 8.1 emulators and targets, and all the rest of the packages (e.g. Office Development packages, etc.).
So I grabbed such a laptop, and installed Xamarin on it, using the official download URL on their site. It installed fine, but when I tried to create a new Forms project, it only created the Android part of it, no WP or iOS projects were created.
After checking the settings and all, it turns out that Xamarin Studio won't load the iOS and WP parts which would make it possible to create the projects.
How could I make it see those extensions?
You will need to download the Windows phone SDK update and that will create Windows phone project for you
I've downloaded the Windows Phone 8.1 SDK Update and I'm attempting to make a Windows Phone 8.1 project. I've updated visual studio with the latest patches but the only template options I have for 8.1 is the standard Windows Store apps as seen in the screenshot below:
Windows Store
Any idea how I can get "Windows Phone" to appear with the appropriate OS target?
I think you didn't install everything. Because i've got actually another screenshot. Following this link you must install Visual Studio 2013 Update 2 - everything needed for WP8.1 is there. Also if you wish to develop Windows Store apps (universal or something) you should install Windows 8.1 SDK from here
Look a bit bown in the list on your screenshot. On the same level the 2nd last option is Windows Phone. That should be it.
I have just downloaded agsXMPP SDK from this link , I opend the source code and I want to build the .dll so it would work for Windows Phone, since it's made for Winforms.
So is it possible to do so? If so how can I do that?
it does not build without modifications for Windows Phone. Sockets are totally different on Windows Phone and other required namespaces are missing. This mean you have to make some major modifications to compile it for WP.
The MatriX SDK which you can download on the same page works fine on Windows Phone.
I was trying some code for push notification(which has sender windows phone client and wcf service) in windows phone 7.0.
I then install windows phone 7.1 beta update
and run the same code
but i m getting
"Connection failed because of invalid command-line arguments."
error.
I want to know how to solve this issue......
It seems like you have either have a misconfigured project or a failed installation of the updated SDK.
Your first choice would be creating a new WP7 application that targets 7.0 systems (if still needed). See if you can launch it through the emulator (which I am assuming is the issue). Try reloading the same project again.
In the most extreme case, remove everything WP7 dev-related and re-install the dev tools.