Questions tagged [mvvm-light]

The MVVM Light Toolkit is a set of components helping people to get started with the Model - View - ViewModel pattern in Silverlight, WPF, Xamarin, .NET Core and Windows Phone. It is a light and pragmatic framework that contains only the essential components needed.

The MVVM Light Toolkit is a set of components helping people to get started with the Model - View - ViewModel pattern in Silverlight, WPF, Xamarin, .NET Core and Windows Phone. It is a light and pragmatic framework that contains only the essential components needed.

The main purpose of the toolkit is to accelerate the creation and development of MVVM applications in WPF, Xamarin, .NET Core, Silverlight and Windows Phone.

Like other MVVM implementations, the toolkit helps users to separate the View from the Model which creates applications that are cleaner and easier to maintain and to extend. It also creates testable applications and allows to have a much thinner user interface layer (which is more difficult to test automatically).

More information about the MVVM Light Toolkit can be found on http://www.galasoft.ch/mvvm .

Currently there are versions for .Net 4.5, 4 & 3.5 and a portable version as well.

2856 questions
1
vote
2 answers

WPF & MVVM Light - Closing a child window with buttons via Messenger

In my project I have a child window, multiple instances of which can be open at a time. They take in an instance of an object, display information about it, and return information about it. Right now it's working but I have to close the window with…
Jason D
  • 2,634
  • 6
  • 33
  • 67
1
vote
1 answer

MVVM Light - Event to Command & ListView - SelectedItem

I have looked all over for an answer to this with no luck. I'm using MVVM Light and I have a ListView in one of my views. I would like to find a way to fire a command when the selected item in my ListView is clicked using the 'Event to Command'…
Jason D
  • 2,634
  • 6
  • 33
  • 67
1
vote
1 answer

OnNavigatedTo is called two twice on app resuming

I'm having trouble with my WP8 app. It uses the MVVM light library for the creation of the ViewModel and is also used for the page navigation with Messages. Right now I'm having some problems with the OnNavigatedTo Method of my MainPage. If I start…
Markus Rudel
  • 1,318
  • 15
  • 30
1
vote
1 answer

DataGrid elements not showing after Grouping

I have a DataGrid bound to a ListCollectionView containing a few items grouped with the grouping functionality of the ListCollectionView. If I don't add a GroupDescription (so no items should be grouped), the items get displayed correctly. However…
Kryptoxx
  • 561
  • 4
  • 22
1
vote
1 answer

MVVM - Access command from different class in XAML

In my project I have a TitleView and GameView. When the program launches, TitleView is displayed. The user clicks a button and GameView is displayed. I am using MVVM Light which includes MainViewModel which has commands to switch to the desired…
Jason D
  • 2,634
  • 6
  • 33
  • 67
1
vote
1 answer

RaisePropertyChanged doesn't work for ObservableCollection

I have a really weird problem with update UI using MVVM Light Toolkit. The RaisePropertyChanged doesn't work at all for my ObservableCollection. Here is the XAML code:
Mateusz Dembski
  • 427
  • 1
  • 5
  • 15
1
vote
1 answer

TextBox.Text OneWay Binding Not Responding to Code Behind ViewModel Update

I am currently implementing a search (more properly "filter") form for my View that uses ApplicationBarIconButtons to drive user interactions with the form: a search button to transition to the VisualState with the form displayed, and one to clear…
lsuarez
  • 4,952
  • 1
  • 29
  • 51
1
vote
2 answers

Navigation between view using MVVM in WPF

Im new to WPF and MVVM. Im trying to create Login window using MVVM and i succeeded to create. here is the Login.xmal code.
1
vote
2 answers

What is the purpose of "Design" folder and "Skins" folder in MVVM WPF application created with MVVM Light Toolkit V 4.0?

I bag your pardon. I'm very beginner in MVVM. I installed MVVM Light Toolkit V 4.0 and tryed to create a WPF MVVM application project with it. A project was created successfully. There are following folders in the project: "Design", "Model", "Skins"…
user1688773
  • 157
  • 1
  • 3
  • 11
1
vote
1 answer

C# WPF ToggleButton Changing more than one property in a trigger?

I have a togglebutton and when it is clicked I simply want to change the background and the content. The content changes correctly, but the background changes, but instead of my specified background value, it is a default (?) blue-ish. In previous…
FloppyDisk
  • 97
  • 2
  • 9
1
vote
1 answer

Possible Mvvm-light bug with EventToCommand

Everything starts pretty simple: i have a ListBoxSelector (app is for wp7). Items consists of picture and some text. Items style is stored inside of the StyleTemplate. Image can be tapped, its event is like
Vitalii Vasylenko
  • 4,776
  • 5
  • 40
  • 64
1
vote
1 answer

MVVM Light: Register generic class for messenger

I have a generic ShowMessage class that I want to use to carry data around: class ShowMessage { private readonly T _Data; public string Title { get; set; } public T Data { get { return _Data; } } public ShowMessage( T data) { …
Sascha
  • 10,231
  • 4
  • 41
  • 65
1
vote
2 answers

MVVM pattern - executing view operations

I'm using MVVM Pattern (with MVVM Light) to build my XAML app (win8). I have a ListView, which is bound to a property of my ViewModel. I also have a button that triggers an operation on that ViewModel, which updates that property (which results in…
filip
  • 1,444
  • 1
  • 20
  • 40
1
vote
2 answers

Catching pressing "Back" button in mvvmlight

How can i move protected override void OnBackKeyPress(System.ComponentModel.CancelEventArgs e) to the viewmodel and still be able to control "back'ing"? In the codebehind, i can use e.Cancel = true;, but how to use it in the viewmodel?
Vitalii Vasylenko
  • 4,776
  • 5
  • 40
  • 64
1
vote
1 answer

How to communicate OpenFileDialog result "FilePath" from view to view Model?

I am trying to open a file dialog by pressing a button on view and view call a command "OpenFileDialog" which is defined in viewmodel. That method send a message to view to open the "Microsoft.Win32.OpenFileDialog()" and now I want to communicate…
User1551892
  • 3,236
  • 8
  • 32
  • 52
1 2 3
99
100