locked
How to be able to check a checkbox by clicking so that the converter can change the visibility of other controls? RRS feed

  • Question

  • Hi, is there any way to change the state of a checkbox so that the i can view it though design view when the  converter is used to change the visibility of other controls by depending on the isChecked state of the checkbox? I can't using storyboard for this.

    Thanks in advance
    • Edited by nyc9 Wednesday, August 13, 2008 9:57 AM error in title
    Wednesday, August 13, 2008 9:49 AM

All replies

  • Hi,

         The best solution for ur problem is binding element property.


         In expression blend it is pretty simple.

         1.right click the visibility of the controls u want to change, go to Data Binding.
         2.Click "Element Property"(in center)
          2.Select ur  checkbox from left column and select the isChecked property from right column.

    Thats it!!!!!!!!!
      
    Tuesday, August 26, 2008 5:39 PM
  •  After step 3, you should do these steps:
        4. Expand the Advanced properties by click on the expand button in Creating Data Binding dialog
        5. Click on the button for Value Converter, and select BooleanToVisibilityConverter in System.Windows.Controls

    Then click ok button to close the data binding dialog

    Do these steps because it cannot converter the Bool value to Visibility by default. So we should add a data converter for that
    Wednesday, August 27, 2008 3:50 AM