1,847 questions
1
vote
2
answers
4k
views
WINUI3 - Customize TitleBar
Just a quick clarification needed regarding .setTitleBar() usage.
MainWindow.xaml
<Window
x:Class="Wrath.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/...
0
votes
1
answer
541
views
What is the best way to output Bitmap in a window (WPF)?
What I want to do:
Given a simple Bitmap (System.Drawing.Bitmap) I am willing to output it to my window in WPF application. I am also willing to do it frequently, creating a frame stream.
What I've ...
3
votes
2
answers
2k
views
What are my options for selecting/opening files and folders when using WinUI3/Project Reunion 0.5?
There is literally no working API available which allows users to simply click a button in my app and be presented with a dialog box which would allow them to select files. Am I missing something here?...
1
vote
1
answer
4k
views
What is the proper way to reference an image in winui
I am trying to display an image using the latest version of winui, without success.
Due to my lack of progress I assume I must be doing something terribly wrong, however, I can't determine what that ...
6
votes
6
answers
6k
views
How to Maximize, Minimize, Restore WinUI window from code
I'm creating a demo app using WinUI 3 prerelease 0.5 (project reunion).
I would like to maximize, minimize, and restore the window state from c# managed code. Are there any examples available?
0
votes
1
answer
1k
views
NavigationView gives an exception when it's the only thing on the page
I'm using the new Project Reunion 0.5/WinUI3 Preview 5. And after my upgrade from Preview 4, I started to get this error:
Exception thrown at 0x76C5A8B2 in ReunionTest.exe: Microsoft C++ exception: ...
3
votes
0
answers
748
views
How to incorporate Win UI with Prism across the Uno platform?
I fetched the Prism Blank App (Uno Platform) template to set up a basic PrismApplication in the shared project. Probably a very good reason, it is a blank template, therefore even the Win UI Desktop ...
0
votes
2
answers
488
views
Why is this drag n drop between listviews failing?
I copied the code from the Xaml Controls Gallery. When I run and drag the listitem, the app closes. If I run in debug, F10 doesn't lead me to the part of the code that's breaking. In fact, the app ...
1
vote
2
answers
2k
views
Developing C++ WinUI3 Desktop App with MVVM
I am looking at the WinUI3 framework with native C++ support for desktop applications.I cannot see any MVVM support as in C#. Should I expect it will be never supported and go i.e. with MVP with some ...
3
votes
1
answer
184
views
SelectedItem selection lost when updating ItemsSource to the ItemsControl
I have a custom RibbonGallery control like in Excel, MSWord, and Outlook.
Please refer the Excel RibbonGallery image below and Normal selection still exists.
And I kept two ItemsSource, one for ...
0
votes
1
answer
990
views
Image in custom control isn't loaded in UWP (WinUI3 preview 3 C++/WinRT)
I was following the Microsoft tutorial on custom controls(templated) in WinUI3, and decided to fiddle with them (I'm new to WinUI). I've been trying to build an Image Card control, but can't seem to ...
0
votes
1
answer
312
views
How can I safely replace the contents of an ObservableCollection that's serving as a TreeView's ItemsSource?
I'm writing WinUI 3 desktop application. The main window consists of a TreeView with the names of car makes as the parent items, and car models as the children. Here's the relevant code:
MainWindow....
0
votes
0
answers
299
views
.NET 5, WinUI 3, and WinRT APIs available to Desktop Apps
I have two related questions.
(1) Around 4/2019, Microsoft provided a list of APIs that can be called from packaged Desktop apps. (These are in addition to the API that have the DualApiPartition ...
0
votes
1
answer
322
views
TreeView items randomly appear under the wrong parent
Edit 2:
I'm replacing the original text of my question and references to my original code with a simpler example instead, per Peter Duniho's suggestion.
I'm developing a WinUI 3 app. The main window ...
3
votes
1
answer
5k
views
Is there anything similar to WPF-DataTrigger in WinUI UWP project?
I want to change the style based on binding values, for this I used DataTriggers in WPF. Now I'm trying to achieve the same in WinUI project, but since there are no DataTriggers in WinUI I can't go ...
0
votes
1
answer
2k
views
How to navigate to a new page using WinUI3 with C++ desktop app?
Firstly I create a project using template "Blank App, Packaged(WinUI in Desktop)" in Visual Studio.
Then I changed code in MainWindow.xaml to a simple Frame:
<Frame x:Name="rootFrame&...
1
vote
1
answer
1k
views
Get response from post in WebView2 in WinUI 3.0 Preview 3 Desktop App
In the ctor of the code-behind we have the code below copied from microsoft-ui-xaml-specs
MyWebView.WebMessageReceived += (WebView2 sender, WebView2WebMessageReceivedEventArgs args) =>
{
// ...
5
votes
1
answer
682
views
Derive from IconElement or IconSourceElement in UWP
I'm trying to create the same custom symbol icon control as MS SymbolIcon, which will get the enum symbol values as input, and the equivalent path data value will be retrieved from the dictionary<...
0
votes
1
answer
233
views
UWP - CheckBox or Button is not visible
Using
Jetbrains Rider
Universal Windows Platform
Problem
The window is visible, but the buttons are not visible.
Question
How can I fix the problem?
Source code
using System;
using System.Collections....
4
votes
3
answers
769
views
How to bind two different class properties in DataTemplate
I am trying to bind two properties from different classes in DataTemplate.
<DataTemplate x:Key="DemoItemTemplate" x:DataType="local:DemoInfo">
<NavigationViewItem ...
0
votes
1
answer
1k
views
WinUI 3.0 for desktop apps default project gives runtime error
Using Windows UI Library 3 Preview 2 (July 2020) that was released just yesterday. On latest version of VS2019 - Preview, followed this official tutorial Get started with WinUI 3 for desktop apps to ...
2
votes
2
answers
2k
views
WinUI 3.0 - Why UWP project is asking for MS Edge for Business for WebView2
When I use WebView2 control in a UWP project with WinUI 3.0 and run the app, the webpage inside WebView2 control is not displayed. Instead, the app displays the following message that takes me to ...
2
votes
1
answer
2k
views
How can I find out whether you are using WinUI 2 or WinUI 3?
Currently, I try to learn how to use UWP UI component, in WPF application.
I'm following the examples in https://github.com/rvinothrajendran/XamlIslands
However, may I know, how can I find out, ...
11
votes
3
answers
37k
views
ContentPresenter in UserControl
I'm new to WPF and I'm trying to create an UserControl which will have some nested content.
<my:InformationBox Header="General Information" Width="280">
<StackPanel>
<Label&...