Click here to Skip to main content
16,012,082 members
Home / Discussions / WPF
   

WPF

 
PinnedHOW TO ANSWER A QUESTION PinPopular
Chris Maunder16-Jul-09 3:09
cofounderChris Maunder16-Jul-09 3:09 
PinnedHow to get an answer to your question PinPopular
Chris Maunder16-Jul-09 3:05
cofounderChris Maunder16-Jul-09 3:05 
QuestionApp WPF Pin
Nelson196526-Sep-24 15:39
Nelson196526-Sep-24 15:39 
QuestionRenderTransform Compilation Error Pin
Kevin Marois16-Sep-24 7:15
professionalKevin Marois16-Sep-24 7:15 
AnswerRe: RenderTransform Compilation Error Pin
#realJSOP26-Sep-24 0:53
professional#realJSOP26-Sep-24 0:53 
Question"Refresh" Behavior Pin
Kevin Marois19-Aug-24 11:20
professionalKevin Marois19-Aug-24 11:20 
AnswerRe: "Refresh" Behavior Pin
#realJSOP12-Sep-24 4:10
professional#realJSOP12-Sep-24 4:10 
GeneralRe: "Refresh" Behavior Pin
Kevin Marois16-Sep-24 7:22
professionalKevin Marois16-Sep-24 7:22 
GeneralRe: "Refresh" Behavior Pin
#realJSOP26-Sep-24 0:54
professional#realJSOP26-Sep-24 0:54 
Questionbinding textblock to tabitem textblocks Pin
geomeo12329-Jul-24 17:00
geomeo12329-Jul-24 17:00 
Question[WPF] ComboBox with RichTextBox Pin
Member 846740328-Jul-24 6:36
Member 846740328-Jul-24 6:36 
AnswerRe: [WPF] ComboBox with RichTextBox Pin
Member 846740328-Jul-24 6:44
Member 846740328-Jul-24 6:44 
QuestionHow to create and save High Score in my Tetris game in wpf c#? Pin
Member 162860911-Jul-24 1:03
Member 162860911-Jul-24 1:03 
AnswerRe: How to create and save High Score in my Tetris game in wpf c#? Pin
Richard MacCutchan1-Jul-24 1:20
mveRichard MacCutchan1-Jul-24 1:20 
Questionselect text box lines and remove Pin
geomeo12322-Jun-24 16:30
geomeo12322-Jun-24 16:30 
AnswerRe: select text box lines and remove Pin
Richard Deeming23-Jun-24 21:47
mveRichard Deeming23-Jun-24 21:47 
GeneralRe: select text box lines and remove Pin
geomeo12324-Jun-24 7:52
geomeo12324-Jun-24 7:52 
QuestionCustom Control Based On Combobox - Replace Part Of The Combobox Pin
Kevin Marois14-Jun-24 18:27
professionalKevin Marois14-Jun-24 18:27 
AnswerRe: Custom Control Based On Combobox - Replace Part Of The Combobox Pin
Dave Kreskowiak15-Jun-24 5:48
mveDave Kreskowiak15-Jun-24 5:48 
GeneralRe: Custom Control Based On Combobox - Replace Part Of The Combobox Pin
Kevin Marois15-Jun-24 10:13
professionalKevin Marois15-Jun-24 10:13 
QuestionInvoke WPF Pin
geomeo1231-Jun-24 15:31
geomeo1231-Jun-24 15:31 
AnswerRe: Invoke WPF Pin
Richard Deeming3-Jun-24 21:38
mveRichard Deeming3-Jun-24 21:38 
GeneralRe: Invoke WPF Pin
geomeo1234-Jun-24 17:54
geomeo1234-Jun-24 17:54 
QuestionICommand Wpf form load properties? Pin
geomeo12330-May-24 14:11
geomeo12330-May-24 14:11 
AnswerRe: ICommand Wpf form load properties? Pin
Richard Deeming30-May-24 21:26
mveRichard Deeming30-May-24 21:26 
geomeo123 wrote:
Do I put the above in my wpf form load event and make these public so that my modelview class can see them?
No. The ViewModel should not have any reference to the view.

The quick fix would be to move the serial port comms into the ViewModel.

A better option would probably be to move it to a separate "service" class consumed by the ViewModel, particularly if you want to introduce unit tests for your ViewModel classes.



"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer

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.