uwp

Windows UWP - Modify AppX Package At Runtime

旧城冷巷雨未停 提交于 2019-12-11 06:32:21
问题 We need to dynamically load assemblies at runtime in order to include customization for our users. However, after looking all over the web, I cannot find any information on whether Microsoft plan to make this feature possible or not. I have started a feature request here: https://wpdev.uservoice.com/forums/110705-universal-windows-platform/suggestions/18145291-dynamically-load-assembly Failing that, I figured that it may be possible to manually add assemblies in to the AppX package, and then

ResourceContext.GetForCurrentView call exception

余生长醉 提交于 2019-12-11 06:29:22
问题 My users of the application have an exception when UWP app call this: Windows.ApplicationModel.Resources.Core.ResourceContext.GetForCurrentView() Exception: 'STOWED_EXCEPTION_System. UnauthorizedAccessException '. I am call ResourceContext.GetForCurrentView for receive "LayoutDirection". I did not find information about this problem in MSDN and other sources. Please, tell me, how i can get "LayoutDirection" other way or eliminate exception? Thanks. EDIT $44_System::Runtime::InteropServices:

UWP change style of ListView DataTemplate in a MasterView

别等时光非礼了梦想. 提交于 2019-12-11 06:26:22
问题 This is the structure of the XAML: <controls:MasterDetailsView ItemsSource="{x:Bind Artists}"> <controls:MasterDetailsView.MasterHeader> // Some Code </controls:MasterDetailsView.MasterHeader> <controls:MasterDetailsView.ItemTemplate> // Some Code </controls:MasterDetailsView.ItemTemplate> <controls:MasterDetailsView.DetailsTemplate> <DataTemplate x:DataType="data:ArtistView"> <Grid> <Grid.RowDefinitions> <RowDefinition Height="Auto" /> <RowDefinition Height="*" /> </Grid.RowDefinitions>

PathGeometry in ResourceDictionary

拟墨画扇 提交于 2019-12-11 06:25:40
问题 In WPF I used to have my vector icons in ResourceDictionary like this: <PathGeometry x:Key="BackIconGeometry">M9.5,0 L16,0 8.75,7 22,7 22,11 8.75,11 16,18 9.5,18 0,9 z</PathGeometry> and reference it from application like this: <Path Data="{StaticResource BackIconGeometry}" Style="..." /> In UWP I'm getting error: A value of type 'String' cannot be added to a collection or dictionary of type 'PathFigureCollection' How can I store my icons data in resource dictionaries? I would like to avoid

How to know the element render size have change by other Control?

£可爱£侵袭症+ 提交于 2019-12-11 06:24:31
问题 I need an element that can know when it's render size has changed. The render size not the ActualSize and it's the element size in screen. And I can get the size but cant know when it's changed. For the element is in the ViewBox or in other Control that is in ViewBox and when the ViewBox change size, the element should know that it's render size has changed. <ViewBox> <OtherControl> <Element>How can the elementh know it's actual size has changed</Element> </OtherColtrol> </ViewBox> I cant do

No IsManipulationEnabled property in UWP

 ̄綄美尐妖づ 提交于 2019-12-11 06:12:51
问题 I have a UWP application where I am trying to enable manipulation events on the UI elements. I subscribed to the ManipulationStarted event but realized that it was not firing. Then, based on some suggestions, I tried setting IsManipulationEnabled property on the Grid but started getting compilation error saying that IsManipulationEnabled property could not be found. Am I missing out on something? 回答1: IsManipulationEnabled is a WPF property. In order to get manipulation events in UWP, you'll

Items in ItemsControl takes width of First Item

淺唱寂寞╮ 提交于 2019-12-11 06:12:06
问题 WrapGrid in ItemsControl takes the width of the first item as the default width of all children items. Is there any workaround to make the itemwidth stretch according to each individual item's content? Here's My XAML. <Grid Grid.Row="2"> <ItemsControl Grid.Column="1" ItemsSource="{x:Bind articleTags}"> <ItemsControl.ItemsPanel> <ItemsPanelTemplate> <WrapGrid Orientation="Horizontal"/> </ItemsPanelTemplate> </ItemsControl.ItemsPanel> <ItemsControl.ItemTemplate> <DataTemplate> <Border

Can merged resource dictionaries access resources from App.xaml?

浪子不回头ぞ 提交于 2019-12-11 06:10:40
问题 Can merged resource dictionaries access resources from App.xaml ? The goal is to split the style to have it more readable. This is what I'm looking for, but doesn't work in that way: App.xaml in UWP project <Application.Resources> <ResourceDictionary> <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="Styles\DefaultButtonStyle.xaml"/> </ResourceDictionary.MergedDictionaries> </ResourceDictionary> <!-- other custom styles, definitions, ThemeDictionaries, ... --> <Color x:Key=

Multiple DataTemplates with UWP MapItemsControl

五迷三道 提交于 2019-12-11 06:04:17
问题 I have a MapControl in UWP: <maps:MapControl x:Name="BikeMap" ZoomLevel="17" Center="{Binding CenterPoint, Mode=TwoWay}"> <maps:MapItemsControl x:Name="MapItems" ItemsSource="{Binding BikePoints}" ItemTemplate="{StaticResource BikePointTemplate}"/> </maps:MapControl> and am adding MapElements using XAML data templates, my ItemsSource is a list of simple objects. But, UWP doesn't seem to provide a way to specify the DataType of a DataTemplate and the MapItemsControl doesn't have a property for

UI not updating when a property changes

╄→гoц情女王★ 提交于 2019-12-11 06:01:32
问题 I have the Contact class that implements the INotifyPropertyChanged: public class Contact : INotifyPropertyChanged { public Contact(Contact contact) { this.Username = contact.Username; this.GUID = contact.GUID; this.Msg = contact.Msg; this.Ring = contact.Ring; } private string username; public string Username { get { return username; } set { username = value; NotifyPropertyChanged(nameof(Username)); } } public Guid GUID { get; set; } public bool Msg { get; set; } private bool ring; public