winrt-xaml

Mysterious “Not enough quota is available to process this command” in WinRT port of DataGrid

 ̄綄美尐妖づ 提交于 2019-11-27 20:22:35
Edit Sept 26 See below for the full background. tl;dr: A data grid control is causing odd exceptions, and I am looking for help isolating the cause and finding a solution. I've narrowed this down a bit further. I have been able to reproduce the behavior in a smaller test app with more reliable triggering of the erratic behavior. I can definitely rule out both threading and (I think) memory issues. The new app uses no Tasks or other threading/asynchronous features, and I can trigger the unhandled exception simply by adding properties that return a constant to the class of objects shown in the

Hide Status bar in Windows Phone 8.1 Universal Apps

人走茶凉 提交于 2019-11-27 18:57:07
How to hide the Status bar in Windows Phone 8.1 (C#, XAML)? In Windows Phone 8 it was done by setting shell:SystemTray.IsVisible="False" at any page. But its not available in Windows Phone 8.1 Muhammad Umar With the release of Windows Phone 8.1 SDK comes a new StatusBar. The StatusBar replaces the SystemTray from Windows Phone Silverlight Apps. Unlike the SystemTray, the StausBar can only be accessed via code and some functionality has changed. StatusBar statusBar = Windows.UI.ViewManagement.StatusBar.GetForCurrentView(); // Hide the status bar await statusBar.HideAsync(); //Show the status

Is there a possibility to start another App or Program from a Windows 8 Store App (C#)

安稳与你 提交于 2019-11-27 16:16:59
I want to start another App or Program from my Windows Store App. For example my App is showing emails, so if someone clicks on such an email Outlook should open. Is this possible in an "App-Sandbox"? It is not possible to just launch an arbitrary application, but with custom protocol activation you can launch an app that handles that protocol and if it is not installed - the OS will ask the user to install it. It means that if you can define a custom protocol in your app - you can launch it from another app with this protocol assuming no other app registers to handle it. An example of that is

Windows 8 Winrt Application goes to background or close

删除回忆录丶 提交于 2019-11-27 15:46:20
How can you tell when a windows 8 Metro app gets put in the background? The suspended state doesn't activate. I have a break point on. It only hits if I close the app. I am using a webcam and since no apps can run in the background I need to save my work when it's put in the background. The windows phone it was application deactivated. any help would be nice. Apps do not normally get suspended when in the debugger. However, you can force a suspend when debugging by: Enabling the Debug Location toolbar (red arrow in image below). Then press the Suspend button (blue arrow). The suspending event

MediaElement in WinRT / Win8 does not work at all

感情迁移 提交于 2019-11-27 15:21:31
I'm getting really frustrated with WinRT (Windows 8 apps). I've been running into a lot of problems with the most basic functionality and no documentation to support it. So, here's my next question of the series I've already posted regarding WinRT: <MediaElement Width="500" Height="500" Source="ms-appx:///Assets/SampleVideo.wmv" /> Why doesn't this work?!!! No video displays. No audio played. No error messages. No exceptions thrown. None of these events are raised: MediaOpened MediaFailed MediaEnded SeekCompleted DownloadProgressChanged BufferingProgressChanged The only event raised is

Windows 8 ListView with horizontal item flow

Deadly 提交于 2019-11-27 15:06:26
How can i make the ListItems inside windows 8 ListView to flow horizontally. Default behavior is vertical, but i want to show the list in horizontal flow so it can render as panorama. I tried GridView which does support horizontal layout but there is a limitation on item height which does not show the complete item content for items with large text. You can use a ListView this way: <ListView Height="500" VerticalAlignment="Center" ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Disabled" ScrollViewer.HorizontalScrollMode="Enabled" ScrollViewer

Executing UI Code from ViewModel on MVVMCross

断了今生、忘了曾经 提交于 2019-11-27 13:20:49
问题 I have just started using MvvmCross, but i didn't find any info about to how i can execute UI code from a ViewModel. On Caliburn there are coroutine so i can access the view and keep the ui code separated from the viewmodel code. on my first case i need to open a dialow from a command inside a ViewModel, what is the correct way? Right now i'm developing a WinRT app. Thanks 回答1: There isn't any hard/fast rule on this within MvvmCross. Generally, when I need to do this I use the Messenger

XAML/C#: What event fires after reordering a gridview?

人盡茶涼 提交于 2019-11-27 12:30:41
I am making my first Windows Store app in Visual Studios 2012. I have a gridview control that I have enabled to be reordered. I have code that I need to run when the list is reordered. I have tried the Drop event. It does not fire. I tried several other drag events, which also did not fire. It seems like this should be so simple... Thanks for your time! Jerry Nixon - MSFT You cannot reorder a GridView unless the ItemsSource is bound to an ObservableCollection and CanReorderItems , CanDragItems , and AllowDrop are set to true . It is not necessary to use a CollectionViewSource to enable

Adding a swipe gesture to open SplitView Pane

笑着哭i 提交于 2019-11-27 10:48:59
I am trying to add a swipe gesture to the SplitView control (aka "hamburger menu") of UWP, similar to the swipe left/right of a Pivot control. How can I set a gesture to change the Display mode of it? In iOS 8 and later, I can use UISplitViewController and set presentsWithGesture property to do that but there is not a similar thing in WinRT. Now after reading this blog: http://blogs.msdn.com/b/cdndevs/archive/2015/07/10/uwp-new-controls-part-2-splitview.aspx , I realized that there is the DisplayMode property in SplitView control and I should use VisualStateManager to change the state of it

how to calculate the textbock height and width in on load if i create textblock from code?

五迷三道 提交于 2019-11-27 09:16:49
TextBlock tbl= new TextBlock(); tbl.text="Kishore"; double x=tbl.ActualHeight; double y=tbl.ActualWidth; If i execute the code from the loaded event in Metro - winRT will return 0 for both. How can I get the ActualWidth in the Loaded or SizeChanged event? Filip Skakun Call Measure() then Arrange() and then ActualWidth and ActualHeight will be updated. Can also do this via UpdateLayout(); testBlock.ActualWidth This could be useful when calculating multiple objects heights and widths. TextBlock tbl = new TextBlock(); tbl.Text = "Kishore"; tbl.Measure(new Size(0, 0)); double x = tbl.ActualHeight;