Questions tagged [stylet]

Stylet is a .NET Library for implementing a ViewModel-first MVVM framework with WPF. Stylet is inspired by Caliburn.Micro, and shares many of its concepts.

More information can be found here: Github Link

Stylet supports the following:

  • IoC Dependency Injection
  • Has it's own MessageBox for use in MVVM
  • Links the View and ViewModel
  • Removes BoilerPlate code for INotifyPropertyChanged Interface
13 questions
1
vote
1 answer

Adding a AnchorablesSource in AvalonDock using MVVM ViewModel first

I having problems adding an AvalonDock AnchorablesSource under a ViewModel first MVVM approach using Stylet. My avalonDock XAML is as follows:
Richard
  • 439
  • 3
  • 25
1
vote
1 answer

Adding Views/ViewModels to an ObservableCollection when using ViewModel-First MVVM Stylet framework

When using a ViewModel first MVVM pattern, how can you add your ViewModels to an ObservableCollection so they can be bound into another View and appear as a view? I’m using AvalonDock, and I’m struggling to bind the LayoutDocument panes in…
Richard
  • 439
  • 3
  • 25
0
votes
0 answers

How to get multiple selection in WPF datagrid using stylet mvvm?

I've a VB.net WPF application that display data on a datagrid. I need to get the selected rows; XAML
0
votes
0 answers

Injected ViewModels are not visible in a WPF content control unless re-initialised

I have a content control as follows: This binds to the following property in…
Richard
  • 439
  • 3
  • 25
0
votes
1 answer

Stylet MVVM binded VM don't show view

As the code showed below I have the main RootViewModel and View where I placed a Content Control, and binded it to ActiveItem. My iusse is that when clicking the button the RedView is not showed, instead is drawed the text …
user18107302
0
votes
0 answers

How to open a WPF window, and run a Method, only once the view has loaded and is visible

I'm using MVVM ViewModel first with Stylet. I have a method that takes a long time to run called Run in my Simulation class and I want to open window with a status bar which has a viewModel called StatusViewModel. The result I am getting is a blank…
Richard
  • 439
  • 3
  • 25
0
votes
0 answers

Why I'm receiving Access Violation Exception when try to dispose VideoView in LibVLCSharp

I'm using Stylet as MVVM framework and LibVLCSharp.WPF 3.6.5 + VideoLAN.LibVLC.Windows 3.0.16 in my project for streaming camera rtsp streams. VideoView is included in my VLCPLayer custom user control, and that control is exposed as a property in my…
0
votes
1 answer

Share a boolean property between the mainviewmodel and the others viewmodels in Stylet MVVM (vb.net)

I'm working on a wpf app using Stylet MVVM framework (VM first approach). In MainViewModel I have a property called IsProjectLoaded, that work as a flag to known if the user has loaded it and do proper actions. This flag should be triggered from the…
user18107302
0
votes
0 answers

Closing a window using ViewModel first MVVM and Stylet

I'm using a MVVM ViewModel first approach with Stylet and I'm struggling to close a window from it's ViewModel. In the Stylet Wiki it states that I can use: Screen.RequestClose I have the following code: public class MdExportViewModel : Screen { …
Richard
  • 439
  • 3
  • 25
0
votes
1 answer

Displaying only available letters from an observable collection to a datagridview

Maybe this is a bad design idea, but this is what I had in mind: public class NetworkDrive : BaseNotify { private char letter; public char Letter { get => letter; set => SetAndNotify(ref letter, value, nameof(Letter)); …
Guapo
  • 3,446
  • 9
  • 36
  • 63
0
votes
1 answer

1 Control, two separate binding sources

Good Morning! I have a WPF application that will display a number of different file types based on command line args it receives. It works fine, but I want to go back and refactor it. I have only been a developer for a few years and would like to…
0
votes
1 answer

How to keep Views and ViewModels in seperate NameSpaces (, and assemblies) in Stylet

I have started using Stylet for MVVM in WPF. I have my Views in the namespace StyletProj.Pages with the Bootstrapper in the namespace StyletProj, and my ViewModels in the namespace StyletViewModels.ViewModels (in another assembly). I need to have…
rzk3
  • 183
  • 1
  • 5
-1
votes
2 answers

Stylet Button not enabling when its CanX property returns true

Using Stylet I'm using the default Stylet template with dotnet core 3.1. I simply added a property/method for reproducing the issue.
mariocatch
  • 8,305
  • 8
  • 50
  • 71