170,136 questions
1
vote
0
answers
47
views
Items on canvas are out of position until zoom/pan/item added [closed]
Sample project here https://github.com/hasstrictlyff14/TimelineComponent
I am trying to create a zoomable/scrollable "timeline" like component. This component has an ItemsSource that I am ...
-4
votes
1
answer
56
views
Confused about binding path and indexers [closed]
This is an example from .NET Documentation Binding Path Syntax:
"Indexers and sub properties can be mixed in a Path clause; for example, Path=ShoppingCart.ShippingInfo[MailingAddress,Street]"...
2
votes
0
answers
53
views
Wrong runtime selected
I'm trying to create an addin in Revit 2025. But I encounter an unknown build error:
error MC1000: Unknown build error, 'Could not load type 'System.Security.SecurityRulesAttribute' from assembly '...
2
votes
1
answer
33
views
Is it possible to prevent only a single row from being excluded and edited in a DataGrid?
I have the following DataGrid:
<DataGrid x:Name="DataGrid" SelectedItem="{Binding Path=SelectedSupplier, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
ItemsSource=...
0
votes
2
answers
47
views
WPF, ShutdownMode and multiple windows
I want to convert an older program from WinForms to WPF.
This program has some mandatory settings (for instance the data file to use).
So, the old program checks at startup whether these settings have ...
0
votes
0
answers
53
views
Selection of all row very slow in DataGrid
I wrote this table to display some data (a lot, all the pixels of an image, with some other mathematical calculations).
I wanted to add a custom filter for every column so i added the DataGrid....
0
votes
0
answers
23
views
How can I use a string resource in data binding StringFormat property? [duplicate]
I'm trying to apply a string formatting to a numeric data binding value. The string formatting text is supposed to be localized and taken from the class generated by Visual Studio for .resx files.
...
0
votes
0
answers
60
views
How can I make an inner WPF Grid automatically adapt to the rows/columns of an outer Grid? [duplicate]
Imagine a UserControl that contains a 3x3 Grid. Let's name it OuterGrid. The OuterGrid defines the content from P(0,0) to P²(0,2). Now you have an InnerGrid that is always a 1x3 Grid. I want the ...
2
votes
0
answers
159
views
Displaying a large image, wildly different memory usage on different PCs [closed]
I am displaying a large image in a WPF app. 108000x960 pixels. It works well on a couple of laptops - uses around 1GB of ram, less than 5% CPU, scrolls smoothly across the image. But on two other ...
0
votes
2
answers
84
views
WPF Command CanExecute is not called with the CommandParameter in DataTemplate
For some reason, even though I put CommandParameter first (avoiding the typical mistake), CanExecute is called with null.
This bug was fixed (pull request) in .NET 7.0, along with the order-of-...
-1
votes
0
answers
72
views
ListBox.SelectedItem in ModelView after click on Item is null [closed]
I've implemented MVVM in a WPF application and bound a ListBox.SelectedItem. The binding works, but the SelectedItem in my model view class is null. I've used it without a style in other applications ...
1
vote
0
answers
36
views
Is there a way to edit the size of the titlebar of a ribbonwindow menu bar in WPF? [duplicate]
In fullscreen, the quick access tool bar and the app title are cut off. See the following image:
Is there a way to adjust the height of the titlebar in fullscreen mode?
Window1.xaml:
<RibbonWindow ...
0
votes
0
answers
112
views
RTSP stream on Wpf using Gstreamer
I'm trying to capture a stream from an Axis encoder on a wpf application using Gstreamer SDK, The stream always tends to start in a new window but not the element I created in the WPF itself.
When I ...
1
vote
1
answer
88
views
C# WPF strict MVVM: Basic TreeView SelectedItem ViewModel Problem
I’m trying to bind the SelectedItem of a WPF TreeView to a property in my MainViewModel in a pure MVVM setup (no code-behind).
Since TreeView.SelectedItem is not a dependency property, I created an ...
0
votes
0
answers
56
views
WebView2 control appears on top of all other controls only when running as .exe (but it works fine in Visual studio)
I'm developing a WPF application that uses the WebView2 control.
Every thing works perfectly when I run the application from Visual Studio, but when I run generated .exe (under Debug folder, outside ...