2,853 questions with Windows Presentation Foundation tags

Sort by: Updated
2 answers

treeview with + and lines

hi, how to make treeview with node symbol as + symbol (instead of triangle) which converts to - symbol when expanded, and how to add lines (dash lines) that makes it easy to follow the intendations of the tree. thanks in advance

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2020-08-31T09:08:31.98+00:00
essamce 621 Reputation points
commented 2025-05-09T10:48:01.63+00:00
Puski, Zoltan 0 Reputation points
1 answer One of the answers was accepted by the question author.

Restrict portions of an application - C# Wpf

Hi, i am making a c# wpf application that has several pages and i want to protect certain pages from being accessed by certain users. what would some good aproaches to doing this be? I would really appreciate your help.

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-03-01T04:09:41.4933333+00:00
alan smith 21 Reputation points
accepted 2025-04-19T06:21:43.6933333+00:00
alan smith 21 Reputation points
1 answer

WPF problem with using decimal points with ValidationRule and Lost Focus

here is my Code <StackPanel Grid.Row="2" Grid.Column="0" Orientation="Horizontal" Grid.ColumnSpan="3" Height="auto" Grid.RowSpan="2" > <TextBox …

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2021-04-13T19:01:12.073+00:00
Brandon Boone 21 Reputation points
commented 2025-04-17T19:39:01.5566667+00:00
Abdelghani Sbai Idrissi 0 Reputation points
1 answer

Deployment WPF as self contained

Hi, I used visual studio 17.3.4. I published WPF app as self contained in .NET 9 to folder , the publish process succeeded. But the generating exe is not running ? Why? How it can be solved ? Thanks,

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-04-02T15:00:59.8066667+00:00
Dani_S 4,461 Reputation points
commented 2025-04-10T12:59:45.1466667+00:00
Dani_S 4,461 Reputation points
1 answer

How to Keep New at Top of DataGrid

Consider the following code which sets up a DataGrid: ocExpenses.OrderByDescending(Function(ve) ve.ChargeDate) dgExpenses.ItemsSource = ocExpenses Dim ecv As IEditableCollectionView = dgExpenses.Items ecv.NewItemPlaceholderPosition =…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-04-06T01:20:04.2266667+00:00
RogerSchlueter-7899 1,426 Reputation points
commented 2025-04-08T21:53:36.5866667+00:00
RogerSchlueter-7899 1,426 Reputation points
1 answer

WPF RadioButton Binding Issue with Dictionary in MVVM

Hello, In my WPF project, I'm trying to filter data by binding the IsChecked states of RadioButton controls to a Dictionary<string, object> property named Filters in my ViewModel. However, when users change the IsChecked state, the setter of…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-04-04T08:26:27.4533333+00:00
fatih uyanık 225 Reputation points
commented 2025-04-04T17:25:09.4633333+00:00
fatih uyanık 225 Reputation points
1 answer

WPF MVVM: Dictionary<string, bool> Binding Issue (SetProperty Not Triggering)

Hello In my WPF MVVM project, I'm using a Dictionary<string, bool> to store filtering options. I'm updating this dictionary using the SetProperty method and binding it to the IsChecked property of RadioButton controls in my UI. However, when the…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-04-03T11:32:15.2066667+00:00
fatih uyanık 225 Reputation points
commented 2025-04-04T17:24:19.2633333+00:00
fatih uyanık 225 Reputation points
0 answers

Win11 - User32.GetRawInputData fails to read data since 24H2

Background: We are using HwndHost class to host child window inside WPF application. From WndProc method we are forwarding input messages (WM_INPUT) to child process/window using User32.SendMessage. The child process/window WndProc method then receives…

.NET
.NET
Microsoft Technologies based on the .NET software framework.
4,103 questions
Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
11,490 questions
asked 2025-01-28T16:38:45.1933333+00:00
Vít H 0 Reputation points
edited a comment 2025-04-03T06:38:50.32+00:00
현성 김 0 Reputation points
2 answers One of the answers was accepted by the question author.

How to Put New Row at Top of DataGrid

I have a DataGrid with a DataTable as its Source. I would like the new row to be at the top of the grid. All of the pages I've looked at for NewItemPlaceholderPosition show it to be a property of an IEditableCollectionView. Is there a way to put the…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-04-02T00:00:04.76+00:00
RogerSchlueter-7899 1,426 Reputation points
accepted 2025-04-03T04:43:40.2666667+00:00
RogerSchlueter-7899 1,426 Reputation points
2 answers

Understanding %temp%\.net Folder | WPF | Single File | Self Contained | WebView2

When developing a single file self-contained WPF application using .NET 8 that uses the WebView2 component, a folder is created under %temp%\.net while the application is running. What is the purpose of this folder, when and how is it created, and is it…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-03-28T09:27:04.87+00:00
Theiss, Daniel 0 Reputation points
edited an answer 2025-04-02T10:37:49.7166667+00:00
Theiss, Daniel 0 Reputation points
1 answer

Impact of Changing Framework Order in runtime.config.json on Application Stability

Description: I am working on a .NET 8 WPF application that undergoes obfuscation using SmartAssembly. During the build, runtime.config.json is generated automatically, but SmartAssembly picks WindowsBase.dll from Microsoft.NETCore.App instead of…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-03-28T09:11:43.6833333+00:00
Subhabrata Sahoo 0 Reputation points
commented 2025-04-02T01:09:39.98+00:00
Hongrui Yu-MSFT 5,255 Reputation points Microsoft External Staff
3 answers One of the answers was accepted by the question author.

DataGrid TextBox Search using Ctrl + F and F3

I am building a WPF MVVM application. I have a DataGrid, like so: <DataGrid Name=“Employees” AutoGenerateColumns=“False” CanUserAddRows=“False” EnableColumnVirtualization=“True” …

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
XAML
XAML
A language based on Extensible Markup Language (XML) that enables developers to specify a hierarchy of objects with a set of properties and logic.
846 questions
asked 2021-11-11T14:05:22.47+00:00
StashyCode 61 Reputation points
commented 2025-04-01T08:48:52.2466667+00:00
CodingNinja 96 Reputation points
1 answer

UI Slows Down When Listing Large Data (3000+ Records) in WPF Application

Hello,    I am developing a library automation system using WPF and MVVM. My application contains more than 3000 book records, which I list using ICollectionView and ObservableCollection. However, while loading and displaying the data, the UI slows down…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-03-21T07:37:55.05+00:00
fatih uyanık 225 Reputation points
commented 2025-03-31T00:59:28.8166667+00:00
Hongrui Yu-MSFT 5,255 Reputation points Microsoft External Staff
3 answers One of the answers was accepted by the question author.

WPF DataGrid resizing column causes extreme scrolling

I have found a behavior with the stock WPF DataGrid that I can't explain or prevent, but it feels like a bug. I am curious if anyone has run into this and what the fix or workaround is. Steps to Reproduce: When using a DataGrid with several columns…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2020-09-22T18:23:03.063+00:00
Werth, Timothy R 21 Reputation points
answered 2025-03-30T11:44:56.2033333+00:00
CodingNinja 96 Reputation points
1 answer One of the answers was accepted by the question author.

How to control the Visibility property of a UserControl object dynamically using Binding property?

I am working on a .NET C# project to learn MVVM. I am struggling to control the Visibility property of a UserControl dynamically. The login screen (userView.xaml) is a small centralized box that has two userControl views named signInUC.xaml and …

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-03-27T12:30:15.9+00:00
Lakshmanan Balasubramanian 101 Reputation points
accepted 2025-03-28T13:58:45.78+00:00
Lakshmanan Balasubramanian 101 Reputation points
1 answer

How to reference global resources in user controls in wpf class library projects

I created a WPF class library, and then added a UserControl "Card.xaml", and a resource dictionary "GlobalRes.xaml", I hope to use the style resources in GlobalRes in the Card control. As shown…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
11,449 questions
asked 2024-06-21T05:17:59.38+00:00
HoWe Yu 86 Reputation points
commented 2025-03-28T11:46:49.2833333+00:00
Marcos Cordeiro Oliveira 0 Reputation points
1 answer One of the answers was accepted by the question author.

How to get the custom WPF dialog box in visual studio

I am using webview2 to display the page on the wpf dialog box initially the issue is there was visual studio icon that was coming by default on the top left I want to remove that icon so that I used WindowStyle="ToolWindow" due to this my…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-03-20T10:52:16.6966667+00:00
Vasu Bansal 20 Reputation points
accepted 2025-03-27T06:41:57.32+00:00
Vasu Bansal 20 Reputation points
1 answer

Windows 11 22598.100 Tooltip problem with WPF apps

I'm finding that Tooltips in WPF V4.8 apps (and earlier versions) are not working in Windows 11 build 22598.100. They appear but then immediately disappear. It happens in all WPF based apps. Tooltips are ok in Winforms apps and also .NET 5.0 WPF apps are…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
11,490 questions
asked 2022-04-19T14:18:27.207+00:00
Andrew Jones 26 Reputation points
commented 2025-03-25T05:33:16.2833333+00:00
Raymond Wynn 0 Reputation points
1 answer

How to change Windows Lock Screen background without creating a UWP app?

I need to programmatically change the Windows Lock Screen background, but my application's logic is quite complex, and it can't be achieved using the built-in Windows functionalities. I know that it's possible to create a UWP app and use the…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
asked 2025-03-21T03:46:45.3133333+00:00
Moying 0 Reputation points
commented 2025-03-24T01:04:49.59+00:00
Hongrui Yu-MSFT 5,255 Reputation points Microsoft External Staff
2 answers One of the answers was accepted by the question author.

How to number rows in dataGrid

Hello. I am using datagrid. Is it possible to make it possible for the user to add a combined row or with columns by clicking on the table? And how it is possible to make numbering of lines as an example? If a combined string is encountered, then the…

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,853 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
11,449 questions
asked 2023-04-21T19:46:25.7133333+00:00
vitaminchik 486 Reputation points
answered 2025-03-22T07:04:20.99+00:00
Fei Nan 0 Reputation points