uwp

Check progress of download operation which started in background task

送分小仙女□ 提交于 2019-12-23 23:09:58
问题 I have an application where users can download some files and these files can be also downloaded via BackgroundTask triggered by push notification for example. When the app is not running and I receive push notification, BackgroundTask starts to download the file. If I launch the app and the file is still downloading I would like to see progress of it. I am able to get all downloading files BackgroundDownloader.GetCurrentDownloadsAsync() . If I have list of DownloadOperation , am I able to

Is it possible to restrict the user from re-sizing a UWP app?

丶灬走出姿态 提交于 2019-12-23 23:07:47
问题 I am trying to port my existing WP8 app to Windows-10. Planning to release it in phases with just WP10 as primary target for phase-1. However I want to be able to release the same/slightly-scaled-up UI to desktop as well in phase-1. I have been playing around with a sample app trying to restrict window resizing by handling CoreWindow's SizeChanged event and preventing it from propagating. However this doesn't seem to do it for me. I am now wondering is it possible to restrict the user from re

How to access camera preview frames with MediaCapture class in Unity?

ε祈祈猫儿з 提交于 2019-12-23 22:55:52
问题 I am trying to access camera preview frames of Hololens in a script of a Unity application, but I have some problems. I want to access the camera preview with MediaCapture class. I know that it is posible in a UWP application but I want to do it in Unity. In the UWP application need to create a CaptureElement in the XAML page and after that to set the source of this element, like that: captureElement.source = mediaCapture; mediaCapture.StartPreviewAsync(); But in a Unity application I don't

How to pass seleced file details to another page - UWP?

旧巷老猫 提交于 2019-12-23 22:34:33
问题 I have a launcher page(MainPage1.xaml).There is a button to select video file from device. Now I want to play that selected file on next page (MainPage2.xaml). How can I get this selcted file StorageFile file on next page? private async void Button_Click(object sender, RoutedEventArgs e) { StorageFile file; FileOpenPicker openPicker = new FileOpenPicker(); foreach (string extension in FileExtensions.Video) { openPicker.FileTypeFilter.Add(extension); } file = await openPicker

How to implement SearchBox functionality in incrementally(Lazy) loaded ListView of UWP

一笑奈何 提交于 2019-12-23 22:18:50
问题 I have a ListView in UWP Application which binds 100 items on 1st load, then after loading is completed it binds another 100 i.e. it is incrementally loaded. Here is a code : <ListView x:Name="lstWords" ItemsSource="{Binding Items}" DataFetchSize="1" IncrementalLoadingTrigger="Edge" IncrementalLoadingThreshold="5" SelectionChanged="lstItems_SelectionChanged"> <ListView.ItemTemplate> <DataTemplate> <StackPanel> <TextBlock Text="{Binding Name}"></TextBlock> <TextBlock Text="{Binding ID}"

How to Disable DropShadow or any shadow of ContentDialog? UWP, XAML

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-23 20:15:06
问题 I am using ContentDialog with a custom xaml style for it, the contentDialog is supposed to have rounded corners but I can see rectangular shadow... interestingly the shadow doesn't show in Windows 1809 build, it does in 1903. I have seen that when I remove the "Container" border, the shadow goes away but the content dialog is no longer in the center of the page ,it goes to top left. I also tried using the Shadow property, and tried wrapping the code in DropShadow..it does not make the shadow

Ionic 3 Cordova ajax calls fail on Windows 10 (UWP)

南笙酒味 提交于 2019-12-23 20:11:25
问题 I have attempted to ask this previously, buy got no real answers, and have now been struggling for over a month. I just cannot get my ajax calls to work on an Ionic 3 Cordova application built for a Windows 10 UWP. They can access localhost, but not any outside connections. The application works fine on both Android and iOS. I am trying to test this locally on my dev machine. I use a certificate (bought) to sign the application, install this certificate, build the application for Windows, and

UWP Template 10 create a dynamic hamburgermenu

老子叫甜甜 提交于 2019-12-23 20:06:17
问题 I'm pretty noob with UWP stuff. I'm trying to create dynamic hamburger menu. I was able to create PrimaryButtons element, and binding it in XAML worked as espected: var loginButton = new HamburgerButtonInfo(); loginButton.ClearHistory = true; loginButton.PageParameter = ""; loginButton.PageType = typeof(Views.Login); var stackPanel = new StackPanel { Orientation = Orientation.Horizontal }; stackPanel.Children.Add(new SymbolIcon { Symbol = Symbol.Contact, Width = 48, Height = 48 }); stackPanel

g.i.cs files missing, classes no longer contain a definition for InitializeComponent

▼魔方 西西 提交于 2019-12-23 19:43:40
问题 I've been developing a UWP project in my spare time to get a hang of UWP, MVVM and Prism. The project was originally really classic, with no use of MVVM and Prism, and I've been working to get those 2 into the project. I've been relying on https://msdn.microsoft.com/en-us/library/gg405484(v=pandp.40).aspx, https://msdn.microsoft.com/en-us/library/gg405494(v=pandp.40).aspx and https://msdn.microsoft.com/en-us/library/ff921098(v=pandp.40).aspx to work my way through it. Some background: I

How to play a sound from JS in a UWP app?

让人想犯罪 __ 提交于 2019-12-23 19:24:34
问题 I'm developing a UWP that contains a WebApp that has some JS functions that invokes some C# functions. Nowadays, I'm trying to play a sound that I have stored in the Assets folder of my UWP app: This is the function that I'm trying to play of my Windows Runtime Component : public async void Beep() { await CoreApplication.MainView.Dispatcher.RunAsync(CoreDispatcherPriority.Normal, async () => { MediaElement mysong = new MediaElement(); StorageFolder folder = await Windows.ApplicationModel