Click here to Skip to main content
15,916,293 members
Home / Discussions / WPF
   

WPF

 
GeneralRe: client side serial communication Pin
javadadabi20-Jun-12 8:29
javadadabi20-Jun-12 8:29 
GeneralRe: client side serial communication Pin
Pete O'Hanlon20-Jun-12 8:45
mvePete O'Hanlon20-Jun-12 8:45 
GeneralRe: client side serial communication Pin
Gerry Schmitz20-Jun-12 9:34
mveGerry Schmitz20-Jun-12 9:34 
GeneralRe: client side serial communication Pin
javadadabi20-Jun-12 17:21
javadadabi20-Jun-12 17:21 
GeneralRe: client side serial communication Pin
javadadabi29-Jun-12 0:20
javadadabi29-Jun-12 0:20 
QuestionHow to change image at run-time corresponding time of day (24 hour format)? Pin
LAPEC13-Jun-12 12:41
LAPEC13-Jun-12 12:41 
AnswerRe: How to change image at run-time corresponding time of day (24 hour format)? Pin
Mycroft Holmes13-Jun-12 14:25
professionalMycroft Holmes13-Jun-12 14:25 
GeneralRe: How to change image at run-time corresponding time of day (24 hour format)? Pin
LAPEC14-Jun-12 1:23
LAPEC14-Jun-12 1:23 
GeneralRe: How to change image at run-time corresponding time of day (24 hour format)? Pin
Mycroft Holmes15-Jun-12 13:30
professionalMycroft Holmes15-Jun-12 13:30 
QuestionHow to draw a free hand shape (random) on wpf canvas Pin
Farhan Ghumra12-Jun-12 23:39
professionalFarhan Ghumra12-Jun-12 23:39 
AnswerRe: How to draw a free hand shape (random) on wpf canvas Pin
Pete O'Hanlon12-Jun-12 23:53
mvePete O'Hanlon12-Jun-12 23:53 
GeneralRe: How to draw a free hand shape (random) on wpf canvas Pin
Farhan Ghumra13-Jun-12 0:00
professionalFarhan Ghumra13-Jun-12 0:00 
GeneralRe: How to draw a free hand shape (random) on wpf canvas Pin
Farhan Ghumra13-Jun-12 0:38
professionalFarhan Ghumra13-Jun-12 0:38 
QuestionAdding ResourceDictionary to a WPF project gives "does not contain a static 'Main' method suitable for an entry point" error Pin
as_kannan11-Jun-12 23:43
as_kannan11-Jun-12 23:43 
QuestionDependency propertie validation Pin
columbos1492711-Jun-12 20:58
columbos1492711-Jun-12 20:58 
QuestionGeneral question on silverlight Pin
ebrahim rajabloo10-Jun-12 0:49
ebrahim rajabloo10-Jun-12 0:49 
AnswerRe: General question on silverlight Pin
egenis10-Jun-12 5:25
egenis10-Jun-12 5:25 
QuestionLoop multiple Videos in MediaPlayer Pin
mselvaraj9-Jun-12 1:20
mselvaraj9-Jun-12 1:20 
QuestionScreen Scraping Silverlight Web Page Pin
yirgalem8-Jun-12 12:00
yirgalem8-Jun-12 12:00 
QuestionGeneral question on MVVM Pin
jesarg7-Jun-12 6:10
jesarg7-Jun-12 6:10 
GeneralRe: General question on MVVM Pin
jesarg7-Jun-12 9:06
jesarg7-Jun-12 9:06 
I can see how keeping the business logic in the viewmodel makes sense, in which case doing normal event handling in the .xaml.cs file that calls a public method in the viewmodel would seem to suffice.

In the accepted answer in the MSDN thread I linked to, the answerer creates a static class (that the viewmodel is aware of) that specifically knows that the data is bound to a DataGrid (and not a Listview or a third-party data control). That sounds like a severe violation of the MVVM principle to me, in addition to being a pain in the butt to code and maintain.

However, I can't seem to find any examples of handling events that aren't the standard Command event (such as double-click, enter, or leave) elegantly without doing regular event handling in the xaml.cs file, which is frowned upon for some reason.

It feels like there is no real standard, and people are just juggling back and forth between competing bad practices and never really landing anywhere. I'm coding a bunch of WPF interfaces now, and I'd like me and my whole team to have a solid idea of what the best practice is.
GeneralRe: General question on MVVM Pin
jesarg7-Jun-12 12:07
jesarg7-Jun-12 12:07 
AnswerRe: General question on MVVM Pin
Abhinav S9-Jun-12 2:18
Abhinav S9-Jun-12 2:18 
AnswerRe: General question on MVVM Pin
egenis10-Jun-12 5:27
egenis10-Jun-12 5:27 
AnswerRe: General question on MVVM Pin
Cracked-Down10-Jun-12 20:17
Cracked-Down10-Jun-12 20:17 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.