Sending Messages in CommunityToolkit #344
-
Hello
public class TestMessage public class MyViewModel : ObservableRecipient,
}
and MaimWindow.xaml.cs /// /// Interaction logic for MainWindow.xaml /// public partial class MainWindow : Window { private readonly MyViewModel _viewModel;
} What is wrong here ???? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
You need to register the recipient, typically in the constructor; I don't see where you've done this. Have a look at the docs: https://learn.microsoft.com/en-us/dotnet/communitytoolkit/mvvm/messenger |
Beta Was this translation helpful? Give feedback.
You need to register the recipient, typically in the constructor; I don't see where you've done this. Have a look at the docs:
https://learn.microsoft.com/en-us/dotnet/communitytoolkit/mvvm/messenger