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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T01:59:34+00:00 2026-06-03T01:59:34+00:00

I have a MultiselectList Control (from SL toolkit) in which i have data template

  • 0

I have a MultiselectList Control (from SL toolkit) in which i have data template with a check box. This is the xaml code i have:

<toolkit:MultiselectList x:Name="BankMultiSelectList" ItemTemplate="{StaticResource CustomItemTemplate}"/>

and the data template:

<phone:PhoneApplicationPage.Resources>
    <DataTemplate x:Key="CustomItemTemplate">
        <CheckBox x:Name="BankCheckBox" Content="{Binding Path=Name}" IsChecked="{Binding Path=IsSelected, Mode=TwoWay}"/>
    </DataTemplate>
</phone:PhoneApplicationPage.Resources>

The binding is becoming with members in the bank class which is the following:

public class Bank
{
    public Bank() { }

    public Bank(string name)
    {
        this.Name = name;
    }

    public string Name { get; set; }
    public bool IsSelected { get; set; }

    public List<Bank> GetBanks()
    {
        return new List<Bank>()
        {
            new Bank("Eurobank"),
            new Bank("Millennium Bank"),
            new Bank("Attica Bank"),
            new Bank("Ταχυδρομικό Ταμιευτήριο"),
            new Bank("Alpha Bank"),
            new Bank("Τραπεζα Κύπρου"),
            new Bank("Hellenic Bank"),
            new Bank("Probank"),
            new Bank("FBBank"),
            new Bank("CitiBank"),
            new Bank("Τραπεζα Πειραιώς"),
            new Bank("HSBC Bank"),
            new Bank("Εθνική Τράπεζα"),
            new Bank("Εμπορική Τράπεζα"),
            new Bank("Proton Bank"),
            new Bank("Αγροτική Τράπεζα"),
            new Bank("Γενική Τράπεζα"),
            new Bank("Tbank"),
            new Bank("Marfin Egnatia Bank"),
        };
    }
}

In the page load i i fill the ItemsSource of MultiselectList (called BankMultiSelectList) with data from the bank class:

Bank bank = new Bank();
BankMultiSelectList.ItemsSource = bank.GetBanks();

That creates a page with some checkboxes with their names bind from the class method. I want to create a “select all” button in application bar to select all checkboxes at once when i press. How can i iterate through all the checkbox controls of the page in order to, let’s say, set their IsChecked property to true? Thanks in advance for your help.

  • 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-03T01:59:37+00:00Added an answer on June 3, 2026 at 1:59 am

    You could iterate over the elements in the UI and set their checked state. But a much better way to do this would be to set the state of your model and let the bindings do the work of updating the UI for your.

    1. Modify your Bank class to implement INotifyPropertyChanged, specifically on the IsSelected property.
    2. Iterate over all of the instances of this class and set IsSelected=true

    … and you’re done!

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

Sidebar

Related Questions

I have created a MultiSelectList like this: MultiSelectList UsergroupID = new MultiSelectList(_ug.GetUsergroups(), UsergroupID, UsergroupName,
Have converted devise new session from erb to Haml but doens't work, this is
Have a bunch of classes which I need to do serialize and deserialize from/to
Have data that has this kind of structure: $input = [ { animal: 'cat',
I have a problem to get the values and text of the MultiSelectList to
Have a look at this picture alt text http://www.abbeylegal.com/downloads/2009-04-01/web%20part%20top%20line.jpg Does anyone know what css
Have a SomeLib.pro file that contains: CONFIG += debug TEMPLATE = lib TARGET =
Have someone tried out DeCAL in Delphi 2009? I'm thinking about upgrading from 2007,
Have you ever obfuscated your code before? Are there ever legitimate reasons to do
Have you ever created or encountered a self modifying code in Java? If yes,

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.