windows-phone-8.1

Workaround for Visibilty.Hidden state- Windows Phone 8.1 App Development

亡梦爱人 提交于 2020-01-01 14:08:31
问题 I cannot assign the Visibility State to Hidden for a ProgressBar. I've read that in the WPF model, Hidden denotes a visibility state where the object should not render, but should still occupy space in a WPF layout. Silverlight does not support Hidden. Is there a workaround to get the same effect as Hidden in my app? 回答1: Visibility.Hidden is WPF only. Both Silverlight and Windows.UI.Xaml use only Visibility.Visible or Collapsed. You can set the UIElement's Opacity property to zero to prevent

Workaround for Visibilty.Hidden state- Windows Phone 8.1 App Development

落爺英雄遲暮 提交于 2020-01-01 14:07:04
问题 I cannot assign the Visibility State to Hidden for a ProgressBar. I've read that in the WPF model, Hidden denotes a visibility state where the object should not render, but should still occupy space in a WPF layout. Silverlight does not support Hidden. Is there a workaround to get the same effect as Hidden in my app? 回答1: Visibility.Hidden is WPF only. Both Silverlight and Windows.UI.Xaml use only Visibility.Visible or Collapsed. You can set the UIElement's Opacity property to zero to prevent

PhoneGap app crashes on WP8.1

风流意气都作罢 提交于 2020-01-01 12:11:11
问题 tl;dr - I can't seem to get a PhoneGap app to run successfully on WP8.1. There are a number of problems in my process of diagnosing the issue. Setting: I created a PhoneGap 3.4 Windows Phone app, tested it on Windows Phone 8 using Visual Studio 2012 for WP, and submitted it. I got loads of crash reports from people with Windows Phone 8.1. Diagnosing the problem: I went ahead and tried to run the app on a WP8.1 emulator using Visual Studio 2013 for Windows. I get the following error:

Windows Phone 8.1: Check Internet Connection

给你一囗甜甜゛ 提交于 2020-01-01 10:52:28
问题 How can I know if the phone has internet connection? (Whether WiFi or Data) Sometimes the phone is connecting to WiFi without internet connection like HotSpots. So I want a code to know if the phone is connecting to internet. 回答1: You can simply try: if (NetworkInformation.GetInternetConnectionProfile() == null) { //no connection } As you can see in this msdn documentation:NetworkInformation.GetInternetConnectionProfile It will return null if there is "no connection profile with a suitable

Universal App Windows Phone Orientation

不羁的心 提交于 2019-12-31 04:20:28
问题 Recently I was developing a Universal app for both the Windows Phone and Windows Store. In that app, I was trying to fix the Orientation of the App to Landscape. But in WinRT based apps of Windows Phone 8.1, I failed to find any Orientation option. In the Silverlight apps, we can fix the Orientations as we want. But is there any way to fix the Orientation to Landscape mode in the Universal Apps? It will be very helpful if someone help me in this regard. Thanks in advance. :) 回答1: Under WinRT

Error: VB runtime is not loaded

允我心安 提交于 2019-12-31 03:35:08
问题 Edited version, after suggestion from community: In a Windows 8.1 Phone project (Part of a VB.Net Solution with also a Store app and a Portable Class Library) I get this error message: Call not possible because VB Runtime is not loaded. but as far as I can trace the code keeps running in spite of this. Until... eventually an error pops up, telling me that Could not find Windows Runtime type 'Windows.foundation' What I have found so far on this subject seems to have a relation with Silverlight

Convert BitmapImage to byte[] array in Windows Phone 8.1 Runtime

天涯浪子 提交于 2019-12-31 02:53:14
问题 There are a few samples to do this but they are for Windows Phone 8.0 or 8.1 Silverlight. But how can you do this for Windows Phone 8.1 Runtime? 回答1: You cannot extract the pixels from a Windows.UI.Xaml.Media.Imaging.BitmapImage. The most general solution is to use a WriteableBitmap instead of a BitmapImage. These classes are both BitmapSources and can be used almost interchangeably. The WriteableBitmap provides access to its pixel data via its PixelBuffer property: byte[] pixelArray =

WP8.1 application crashes on calling RequestProductPurchaseAsync

[亡魂溺海] 提交于 2019-12-31 01:11:49
问题 I'm writing Audio Player for Windows Phone 8.1 (Runtime) and I use IBackgroundTask for audio . I want to use in-app purchase , but applications crashes on calling var result = await CurrentAppSimulator.RequestProductPurchaseAsync(ProProductId); without any exceptions. This method is called within try-catch block. It happens when application already start IBackgroundTask by calling for BackgroundMediaPlayer.Current (happens after few seconds after call RequestProductPurchaseAsync ). If I call

WebClient doesn't exist on Windows Phone 8.1? Downloading html of site

别来无恙 提交于 2019-12-30 10:25:20
问题 I want to get source code of some website. I found this solution: var html = System.Net.WebClient().DownloadString(siteUrl); But VisualStudio tells that WebClient does not exist in System.Net. How to fix that? Or how to do it other way? PS: does windows phone have some special tag which developers usually use when they looking for some code/solutions? 回答1: WebClient does exist in WP8 like this: WebClient thisclient = new WebClient(); thisclent.DownloadStringAsync(new Uri("urihere");

WP8.1 C# Binding Contact Image

孤者浪人 提交于 2019-12-30 07:43:14
问题 Information Quite simply, I’m attempting to create an app that would display the contacts for a user. I’m also a self-taught programmer, so I have experience with programming in some aspects, but I am relatively new to data-binding in general. To begin, I have a ListView control that has an image binding within it. <ListView x:Name="ContactsView" ItemsSource="{Binding}"> <ListView.ItemTemplate> <DataTemplate> <Image x:Name="ContactImage" Source="{Binding Converter={StaticResource