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 7852813
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T19:30:41+00:00 2026-06-02T19:30:41+00:00

I have simplified example: XAML: <CheckBox IsChecked={Binding Path=IsSelected, Mode=TwoWay} Name=cb /> <Button Name=button1 Click=button1_Click

  • 0

I have simplified example:

XAML:

<CheckBox IsChecked="{Binding Path=IsSelected, Mode=TwoWay}" Name="cb" />
<Button Name="button1" Click="button1_Click" />

Code behind:

public partial class MainWindow : Window
{
    private ObservableCollection<MyObject> collection = new ObservableCollection<MyObject>();

    public MainWindow()
    {
        InitializeComponent();

        collection.Add(new MyObject(true));
        //grid.DataContext = collection[0];
    }

    private void button1_Click(object sender, RoutedEventArgs e)
    {
        collection[0].IsSelected = false;
    }
}

public class MyObject
{
    public bool IsSelected { get; set; }

    public MyObject(bool isSelected)
    {
        this.IsSelected = isSelected;
    }
}

The cb.IsChecked doesn’t change by button clicking though the collection[0].IsSelected is changed.

Even if I uncomment grid.DataContext = collection[0]; – nothing changed.

In real example I have the same checkbox in the item template of a listbox. So the behaviour is the same – the selection of checkboxes don’t change.

  • 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-06-02T19:30:46+00:00Added an answer on June 2, 2026 at 7:30 pm

    You need to implement INotifyPropertyChanged on your MyObject type

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

Sidebar

Related Questions

I have models (simplified example): class Group(models.Model): name = models.CharField(max_length = 32) class Person(models.Model):
As a simplified example, I have the following data classes: public class Employee {
Here's a simplified example of an object I have. What I would like to
Let's consider following, simplified example: We have 2 tabs withing <rich:tabPanel switchType=ajax> , each
I've simplified this example as much as I can. I have a remote function:
Simplified example: I have an object that models a user. Users have a first
I have the following code (asp.net-mvc, jquery) (i have simplified the example to show
[This is a simplified example] I have a collection (myCollection) in which exists three
Simplified example: I have a to-do. It can be future, current, or late based
As a simplified example, if I have the classes template <class T, class U>

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.