uwp

How to collapse child control in listviewitem UWP

无人久伴 提交于 2019-12-04 04:58:19
问题 Universal Windows Platform, C# How can I collapse/expand the child listview of item MainListView listitem from code behind? I have not found anything that works. I'd like to do this on the SelectionChanged event. XAML <ListView x:Name="DestListView" SelectionMode="Single" Margin="0,60,0,0" SelectionChanged="listview_SelectionChanged" > <ListView.ItemContainerStyle > <Style TargetType="ListViewItem"> <Setter Property="HorizontalContentAlignment" Value="Stretch" /> <Setter Property=

Capture Esc Key in UserControl

99封情书 提交于 2019-12-04 04:46:40
问题 I want to create a Custom Popup using UserControl , because this is UWP apps, I want to hide Popup when user press ESC on Keyboard. I try to override OnKeyDown method of UserControl but this method never executed when I press ESC on Keyboard. protected override void OnKeyDown(KeyRoutedEventArgs e) { if (e.Key == VirtualKey.Escape) { this.Visibility = Visibility.Colapse; } } 回答1: I want to hide Popup when user press ESC on Keyboard. In UWP app, consider using CoreWindow.CharacterReceived event

Is there a way to parse a vector path geometry in UWP in code behind?

吃可爱长大的小学妹 提交于 2019-12-04 04:38:20
问题 When rendering vector graphics across different platforms, SVG and the SVG path format works really great. But at the moment its my challenge to realize this on the Universal Windows Platform. I've a given path (taken from SVG file) for example: M 198.09375 723.80859 C 177.18295 774.80866 156.88493 827.84014 140.58594 884.89844 L 140.72461 885.21875 L 142.49609 885.21875 C 161.1353 855.01082 143.6824 808.69757 193.58008 822.50977 C 220.7388 819.58475 192.23555 868.86205 206.17383 873.92578 C

Error when uploading UWP app to Windows Store: Failed to merge PRI file \Resources_split.scale-100.pri

我只是一个虾纸丫 提交于 2019-12-04 04:37:15
问题 I am uploading a latest version of my app to the Windows store but my app is throwing the error: Package acceptance validation error: We encountered a fatal error while parsing the package MyApp.UWP_2.33.0.0_x86_x64_ARM_AppStore.appxbundle: Failed to merge PRI file D:\data\Temp\69b5c2ab-3419-4197-839c-2ef13d218413\Resources_split.scale-100.pri: 80070490. Try again or upload a new package. I do not understand where to even begin to look to fix this error. has anyone else seen this error or

How do I change the accent colour of a Xamarin.Forms UWP application?

亡梦爱人 提交于 2019-12-04 04:29:50
问题 I am developing a Xamarin.Forms UWP application. I am struggling to set the accent colour of my application. This is the colour that is used for certain behaviors by default on controls. For example the Entry control has a default blue highlighting on focus shown below: I have tried a few suggestions from this thread: Change Accent Color in Windows 10 UWP but none seemed to work. I am not sure whether it is because I didn't fully understand how changing the colour for UWP differs for Xamarin

How to add .NET dll reference to UWP project?

♀尐吖头ヾ 提交于 2019-12-04 04:24:49
I have several .NET dll projects for .NETv4.x. I changed version to 4.6.1 and rebuilded without problems. When I try to add referene to them from my UWP project I get error: The project targets '.NETCore' while the file reference targets '.NETFramework'. This is not a supported scenario. I can't also reference .NET projects from 'Add reference...'->'Projects': Unable to add a reference to project But in project settings I can't see anything to change it's target to '.NETCore'. Is it possible to reference .NET4.x project from UWP project or convert it to UWP project type? UWP project can

UWP application: Could not load file or assembly 'System.Runtime.WindowsRuntime, Version=4.0.14.0

让人想犯罪 __ 提交于 2019-12-04 04:02:06
问题 I have a UWP application built using .Net Standard 1.4 using Xamarin I have recently upgraded a couple of my nuget plugins and my UWP project has started giving me the following error: "System.IO.FileLoadException: Could not load file or assembly 'System.Runtime.WindowsRuntime, Version=4.0.14.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)\r\n" Now usually this is quite

Scrollviewer not working on a grid

北城以北 提交于 2019-12-04 03:58:47
Hi I am learning UWP in windows 10, I need to scroll through a grid. They have two pieces of code are very similar, my intent is to scroll in grid2, the first piece of code: <Grid> <Grid.RowDefinitions> <RowDefinition Height="Auto"/> <RowDefinition Height="*"/> <RowDefinition Height="*"/> </Grid.RowDefinitions> <CommandBar VerticalAlignment="Top" Grid.Row="0"> <CommandBar.Content> <TextBlock Name="CurrentDateText" Margin="10,10,0,0" HorizontalAlignment="Left" VerticalAlignment="Bottom" FontSize="22" FontStretch="ExtraExpanded"/> </CommandBar.Content> <CommandBar.PrimaryCommands> <AppBarButton

Missing xaml.xr of a class library file in UWP

て烟熏妆下的殇ゞ 提交于 2019-12-04 03:41:45
问题 I have a class library project which I am using in a UWP project. If I add any usercontrol xaml file in the class library and build it it builds fine. But the UWP project gives an error that it cannot find the .xr file. Do I need to add the .xr file externally in any folder to my UWP project? 回答1: Yeah, for a class library with XAML files, if we want to reference the dll in other project, we need not only the dll itself but also the .xr.xaml file and some other files. Because in UWP

How to print in UWP app?

末鹿安然 提交于 2019-12-04 03:23:56
I am trying to print out something from my UWP app. Basically I've used a WebViewBrush to draw some data on to some FrameworkElement 's (Windows.UI.Xaml.Shapes.Rectangle) - and I want to print one of these Rectangles on each page (one rectangle per page) I was really hoping someone could provide a very simple example of how printing in UWP works. I have tried it myself and I am happy to provide my code, but there are honestly thousands of lines - all of which I've taken from the Microsoft GitHub examples and tried tweaking: https://github.com/Microsoft/Windows-universal-samples/tree/master