Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6123925
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T16:04:26+00:00 2026-05-23T16:04:26+00:00

I am sitting with a problem and hope that you can help me.I’m implementing

  • 0

I am sitting with a problem and hope that you can help me.I’m implementing in WPF MVVM. I’m going to explain as good as I can.
So i have one view. In which i have one big property Examination. In this view i have to be able to change the settings of the property Examination. This goes fine. But, I want to have a button, and a dialog appears. There I can change some specific (other) settings or properties of Examination. I don’t want to do this all in one window so I work with a dialog. I do this in my viewmodel:

private void AlgemeneGegevensClick(object sender, RoutedEventArgs e)
        {
            ToetsBeheerViewModel vm = (ToetsBeheerViewModel)this.DataContext;
            EditAlgemeneGegevens window = new EditAlgemeneGegevens(vm);
            window.Show();

        }

So a window dissapears with some textboxes where i can fill in some specifications of a test. But now my problem is, how do i return this changes (of the examination-object) to the viewmodel? Because I do this in my apart window:

 public partial class EditAlgemeneGegevens : Window
    {
        private ToetsBeheerViewModel toetsb;
        public EditAlgemeneGegevens(ToetsBeheerViewModel vm)
        {
            InitializeComponent();
            toetsb = vm;

        }

        private void button1_Click(object sender, RoutedEventArgs e)
        {
            toetsb.Examination.Course = "blablabla";
        }


    }

So i want to change the Course property of examination in blablabla. But my viewmodel will not know that this property is changed?
Hope you get it.. And can help me please :)?

Thanks..

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T16:04:26+00:00Added an answer on May 23, 2026 at 4:04 pm

    It looks like you’re passing in the ViewModel to your new window…so shouldn’t any changes the new window makes be reflected on that instance?

    If you need a more loosely coupled way of returning results, you can consider a message bus infrastructure for your application. There are several implementations, but here’s a good article:

    http://blog.tonysneed.com/2011/03/03/climb-onboard-on-the-mvvm-message-bus/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I hope you can help me here... I have a conflict with the decimal
I have a Porblem an I hope that someone could help me. I'm reading
Preface: I have a demo of the problem on my personal site (I hope
Hey hope someone can help as I am at my wits end with this!?
I am currently struggling with a side project I hope you can help me
this my first question on here. I hope someone can help. It is to
I have problem with setting proper charset on my jsf pages. I use MySql
I have a problem with setting the TTL on my Datagram packets. I am
I have this weird problem with setting up cookies with PHP. Everything worked fine
I have a problem with setting Browsing Path in Delphi 2009: When I install

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.