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

  • Home
  • SEARCH
  • 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 4018842
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T10:01:57+00:00 2026-05-20T10:01:57+00:00

i made check box in wpf ,Got it from Internet.I want to see which

  • 0

i made check box in wpf ,Got it from Internet.I want to see which item is checked or unchecked.Any idea how to do this
here goes the code

Class

public class CheckedListItem
{
    public int Id { get; set; }
    public string Name { get; set; }
    public bool IsChecked { get; set; }
    public string Email { get; set; }
}

Usage

List<CheckedListItem> AvailablePresentationObjects = new List<CheckedListItem>();
        CheckedListItem item = new CheckedListItem();
        for (int i = 0; i < 10; i++)
        {
            item = new CheckedListItem();
            item.Id = i;
            item.Name = i.ToString();
            item.IsChecked = false;
            AvailablePresentationObjects.Add(item);

        }
        list.ItemsSource = AvailablePresentationObjects;

XMAL

<ListBox x:Name="list"  Margin="3,277,0,0" Height="234" VerticalAlignment="Top" Selec
tionMode="Extended">
                        <ListBox.ItemTemplate>
                            <HierarchicalDataTemplate>
                                <my:RibbonCheckBox Label="{Binding Name}" IsChecked="{Binding IsChecked}"  />
                            </HierarchicalDataTemplate>
                        </ListBox.ItemTemplate>
                    </ListBox>

took it from Here
Checked ListBox

Question is

How to implement property change so
that i can know which item was checked
and which was unchecked

My Code solution

  • 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-20T10:01:58+00:00Added an answer on May 20, 2026 at 10:01 am

    You can get collection of selected items: list.SelectedItems.
    Each item you can cast to CheckedListItem and check that item is checked.
    If you want to handle property changing, you should implement interface INotifyPropertyChanged in CheckedListItem class

    Example of INotifyPropertyChanged:
    Add this to your class and call OnPropertyChanged in properties:

        private boolean _isChecked;
        public boolean IsChecked
        {
            get { return _isChecked; }
            set
            {
                _isChecked= value;
                OnPropertyChanged("IsChecked");
            }
        }
    
        public event PropertyChangedEventHandler PropertyChanged;
    
        protected void OnPropertyChanged(string name)
        {
            PropertyChangedEventHandler handler = PropertyChanged;
            if (handler != null)
            {
                handler(this, new PropertyChangedEventArgs(name));
            }
        }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to check if a value exists in an array made from a
I made a login button and want to check if the user logged in
I've made a program which stores any number of objects of my type Project.
Using jQuery Multiselect plugin and need to check if any selections have been made
I need to have custom checkboxes which wasn't that tricky. I made checkbox_selector to
I've made a custom image for a checkbox and want it to switch between
Is it possible to check if a (MySQL) database exists after having made a
I have made this webpage, you can check it out here http://www.bettingtowin.net/webcam.html I have
i've made a listener that checks is the GPS status is changed.. i want
Please check out this jsfiddle http://jsfiddle.net/rr4GH/1/ As you can see its a round edge

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.