windows-phone-8.1

AppBarButton.Icon doesn't change on runtime

a 夏天 提交于 2019-12-23 18:34:03
问题 I have a problem updating AppBarButton Icon on runtime depending on some conditions. <AppBarButton x:Name="WeekButton" Click="OnClick" Label="SomeText" </AppBarButton> I'm trying to update Icon property in some code behind with this code WeekButton.Icon = new FontIcon() { Glyph = Runtime_Value_Here}; But nothing happens. The button doesn't change. But in any random time when the code works, It MAY change the button. I always see, that the Icon is new in code, but not on screen. None of the

How do I get Geolocation of a street address in Windows Phone 8.1 Universal App?

放肆的年华 提交于 2019-12-23 17:06:03
问题 My windows phone user will be typing in a street address in a text field. I need to get the geolocation of that address string so I can later calculate distance of that geolocation and the phone's current address. So, my question is: How do I get Geolocation of a street address in Windows Phone 8.1 Universal App? I found a solution in this stackoverflow answer, however, it's for the old Silverlight apps and not the new Universal Store app APIs that I'm currently using. 回答1: Here is the code

Retrieving thumbnail of a StorageFile (Video) which is located in the localfolder of the app in WP8.1

混江龙づ霸主 提交于 2019-12-23 15:07:23
问题 I'm trying to get the thumbnail of the StorageFile located inside the application package (LocalFolder) of the app. The storage file is a media file which can be image(jpg or png) or a video (mp4 or wmv). Now when i try to get the thumbnail using GetThumbnailAsync(ThumbnailMode) method of the StorageFile class i get a System.Exception : The component cannot be found. error, while the same thing works fine if the file is image or a video which is not inside the app package. Here is the

How to programmatically change background theme of Win 8.1 or Win 10 UWP app?

柔情痞子 提交于 2019-12-23 13:24:39
问题 I have an app for Windows Phone 8.1 and a UWP version of it. I'd like to change the background of the apps dynamically when it is changed in Windows. Use case would be: Start the app, the background theme is dark. Press the home button on the phone Change the background theme to light Go back to the app (basically switch to it from the background) The theme of the app would change automatically to the new theme I'd like it to be done like this, without a restart. I've seen this in other apps,

AccessViolationException when setting the Text in a RichEditBox

只谈情不闲聊 提交于 2019-12-23 12:19:26
问题 I've spent hours trying to understand what is happening here. I have a RichEditBox that the user can interact with by tapping on it and using the keyboard or by tapping on a couple of buttons that add some characters inside the RichEditBox. This is a method I use: private void ptrPlus_click(object sender, RoutedEventArgs e) { try { myRichEditBox.Document.Selection.Text = ">"; myRichEditBox.Document.Selection.SetRange(this.Document.Selection.StartPosition + 1, this.Document.Selection

SupportedOrientations unavailable in XAML of windows phone 8.1 app?

房东的猫 提交于 2019-12-23 09:41:50
问题 What is the equivalent of this in Windows Phone 8.1 App. When I create a new app, there is no more phone:ApplicationPage <phone:PhoneApplicationPage ... ... SupportedOrientations="Landscape" Orientation="LandscapeLeft" shell:SystemTray.IsVisible="False"> 回答1: Yes, In windows phone 8.1, We can't set supportedOrientations in page's XAML. We can set supportedOrientations of App in Package.appxmanifest only. 回答2: You can force the orientation of any page via code, writing just after the this

Microsoft.Phone.Tasks namespace is not available

冷暖自知 提交于 2019-12-23 08:05:44
问题 Namespace Microsoft.Phone.Tasks is not available in XAML page code behind file of my Windows Phone application. Please see the screenshot. In the properties windows of the project I see: Target: Windows Phone 8.1 Am I missing an assembly reference or something? 回答1: Windows Phone 8.1 XAML apps don't have Microsoft.Phone.Tasks namespace to make common UI framework with windows Runtime APIs. Still you can code up a few tasks by using Windows.ApplicationModel namespace. As you havent claried

Windows Phone 8.1 vs Windows Phone Silverlight 8.1 - is there missing documentation on MSDN?

你离开我真会死。 提交于 2019-12-23 07:26:15
问题 I'm attempting to port some .NET code to a Windows Phone 8.1 (not Silverlight) library and have been banging my head against the wall for a while now trying to understand why System.Net.IPAddress wasn't available. According to the Windows Phone MSDN page, it appears to be available for Windows Phone 8.1 Version Information: Windows Phone OS Supported in: 8.1, 8.0, 7.1 Platforms: Windows Phone and the "regular" MSDN page states Version Information: .NET for Windows Phone apps Supported in:

Windows Phone 8.1 vs Windows Phone Silverlight 8.1 - is there missing documentation on MSDN?

こ雲淡風輕ζ 提交于 2019-12-23 07:24:06
问题 I'm attempting to port some .NET code to a Windows Phone 8.1 (not Silverlight) library and have been banging my head against the wall for a while now trying to understand why System.Net.IPAddress wasn't available. According to the Windows Phone MSDN page, it appears to be available for Windows Phone 8.1 Version Information: Windows Phone OS Supported in: 8.1, 8.0, 7.1 Platforms: Windows Phone and the "regular" MSDN page states Version Information: .NET for Windows Phone apps Supported in:

.net WP8.1/Win10 UWP: Namespace for MapControl not found in Visual Studio Designer

北城余情 提交于 2019-12-23 06:57:26
问题 Edit: the described issue below occurs also in a Win 10 UWP application (VS2015, Win10) when using the MapControl. I have a weird problem using the MapControl in a Windows Phone 8.1 (universal app) application. After adding the control to a page, Visual Studio says The name "MapControl" does not exist in the namespace "using:Windows.UI.Xaml.Controls.Maps". Building the app works, I can deploy it to the phone and the map is shown and everything is fine - but I cannot use the Designer for this