winrt-xaml

Gridview not scrolling horizontally in windows phone 8.1

依然范特西╮ 提交于 2019-12-06 03:27:39
问题 .Gridview not scrolling horizontally in windows phone app instead it is scrolling vertically.I just copy paste the code of my windows 8.1 app to windows phone 8.1 but it is scrolling vertically. here is the xaml code: <Grid> <Grid.Background> <ImageBrush ImageSource="Assets/back3.png"></ImageBrush> </Grid.Background> <Grid.ChildrenTransitions> <TransitionCollection> <EntranceThemeTransition/> </TransitionCollection> </Grid.ChildrenTransitions> <Grid.RowDefinitions> <RowDefinition Height="*"/>

Center popup in XAML

倖福魔咒の 提交于 2019-12-06 02:55:54
问题 I have created a Popup by using the following code, but I can not figure out how to center it I tried to automatically change the margin on runtime, but I could not figure out how to do it, but do anybody has an idea of how to center the popup? It does not has a standard-dimension cause I need to globalize my program <Grid Background="{StaticResource ApplicationPageBackgroundThemeBrush}" Name="MainGrid"> <Popup x:Uid="LoginPopup" IsOpen="True" Name="LoginPopup"> <Grid> <Grid.RowDefinitions>

Windows 8.1 how to automatically wrap grid items?

主宰稳场 提交于 2019-12-06 01:53:20
I'm building a universal app and my Win8.1 app has to show a grid of items. Normally the grid consists of 3 columns, but on smaller screens I want the items to wrap so that there are only 2 columns (or even 1). This is my code: <GridView ItemsSource="{Binding Regions}" IsItemClickEnabled="True"> <GridView.ItemsPanel> <ItemsPanelTemplate> <ItemsWrapGrid Orientation="Horizontal" MaximumRowsOrColumns="3" MinWidth="400" /> </ItemsPanelTemplate> </GridView.ItemsPanel> <GridView.ItemTemplate> <DataTemplate> <StackPanel Orientation="Horizontal" Margin="10"> <Image Source="{Binding Code, Converter=

Why did my XAML suddenly crash?

雨燕双飞 提交于 2019-12-06 01:27:14
I added a "Basic Page" to my project in a folder ("View") that I created within the project. At first all was well, but "all of a sudden" the design view failed and displayed: System.ObjectDisposedException Safe handle has been closed This is the XAML (I hadn't changed a thing in the default XAML generated yet): <common:LayoutAwarePage x:Name="pageRoot" x:Class="TimeAndSpaceLines.View.SectionPage" DataContext="{Binding DefaultViewModel, RelativeSource={RelativeSource Self}}" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

Is FluidMoveBehavior available?

你。 提交于 2019-12-06 01:23:43
I have calls to Grid.SetRow and Grid.SetColumn in my code which I'm trying to animate. According to the answer at http://social.msdn.microsoft.com/Forums/en-CA/wpf/thread/257779f7-b459-43fc-a4a1-f24641c50e09 , it is recommended to make use of FluidMoveBehavior, but it doesn't look like this is available for Windows 8. What are my options for animating the children of a Grid when their positions change? I'm basically looking for a way to achieve linear transition. There is a new built-in feature called Transitions that can be used, here is an intro . Try adding a RepositionThemeTransition to

How to have user prompt dialogs in Windows 8 metro apps?

北城余情 提交于 2019-12-06 01:12:54
I would like to get some user inputs for my app like Name, DOB, etc from a modal window for this I need a dialog to be displayed which would contain the textboxes and other controls. Normally in WinForms/WPF I would create a class inherited from the Form/Window class and use the Show/ShowDialog method to present the form to the user How do I achieve this behavior in Windows 8 metro apps using XAML/C# ? I have looked at the MessageDialog class under the Windows.UI.Popups namespace but its for showing only message like the classic MessageBox. I have looked at another CoreWindowFlyout class and

Windows 8 App The application called an interface that was marshalled for a different thread

为君一笑 提交于 2019-12-06 00:32:49
问题 I am working on a Windows 8 application using c#/XAML. Everything has been working except for this event handler where I get the following error on this line. await RefreshUserInfoAsync(); The application called an interface that was marshalled for a different thread. (Exception from HRESULT: 0x8001010E (RPC_E_WRONG_THREAD)) This Observable Collection is being updated from a push notification handler in the app class and this event handler is in my view model. I'm not using any frameworks

How can I disable tilt animation on GridView/ListView in Win10 Universal app?

三世轮回 提交于 2019-12-05 23:49:15
It used to be I could cancel the tilt effect on GridView/ListView by editing the item container style and removing the storyboard animations. However, when I edit the templates now on Win10 Universal apps, I am not seeing any of the storyboards. Where can I cancel the animation at? Here's the style that's generated for me (and when used, does not disable animation): <Style x:Key="ListViewItemStyle1" TargetType="ListViewItem"> <Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}"/> <Setter Property="FontSize" Value="{ThemeResource ControlContentThemeFontSize}"/>

How do you hide a ListView Item placeholder when it's DataTemplate child is collapsed?

点点圈 提交于 2019-12-05 23:09:08
When the visibility of a CarViewControl is set to collapsed, it still shows a placeholder where it used to be (see screenshot below). Is there any way to completely hide a ListViewItem when it is Collapsed? XAML Code <ScrollViewer> <ListView ItemsSource="{Binding CarVM.UserCars}" ShowsScrollingPlaceholders="False"> <ListView.ItemContainerStyle> <Style TargetType="ListViewItem"> <Setter Property="HorizontalContentAlignment" Value="Stretch"/> </Style> </ListView.ItemContainerStyle> <ListView.ItemTemplate> <DataTemplate> <ctrl:CarViewControl Car="{Binding}" Visibility="{Binding HideCar, Converter

How to programmatically navigate in a FlipView with swipe animations

会有一股神秘感。 提交于 2019-12-05 22:47:11
问题 The Windows Dev Center states regarding the UseTouchAnimationsForAllNavigation property: The XAML FlipView control supports three modes of navigation; touch-based, button-based and programmatic. When a user navigates by touch, the FlipView items scroll smoothly into view. When you set this property to true, the same navigation animation occurs whether the navigation is touch-based, button-based and programmatic. I'm currently navigating from my page's code behind by assigning the SelectedItem