Relative Content

Tag Archive for wpfmvvm

Conditional CellStyling in WPF DataGrid

The following code works as long as I only test one trigger. When I began adding single buttons into each cell, everything seemed fine. However, the issue arose when I added one cell with two buttons and unexpectedly, all other cells also received double buttons

How to execute commands like close, hide a window, or commands to start a process within the MVVM WPF pattern

I’m developing applications using the MVVM pattern on the WPF platform and I can’t figure out how to use commands that are directly related to the View in the ViewModel so that it doesn’t break the pattern. I ran into a problem when I tried to make an authorization window that implied hiding this window after successful authorization, or for example, I need to use animation, but I don’t want to develop it in XAML code, so I wrote C# code and placed it inside the View code, even though it violates the pattern. Please share your development experience with this pattern