![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
| |
| | #1 (permalink) |
| | CheckBox groups In a usercontrol I created a toolbar with some checkboxes grouped by setting a GroupName. everything works fine. But when I use multiple instances of the usercontrol the group extends across the usercontrols. How do I put these checkboxes in distinct groups without writing some code that renames these groups on the fly... Thanks, Erno ---- WPF tutorials: http://blogs.infosupport.com/ernow/articles/1878.aspx |
My System Specs![]() |
| | #2 (permalink) |
| | Re: CheckBox groups Arg! Should be RadioButtons of course... Still, same problem... Erno ---- WPF tutorials: http://blogs.infosupport.com/ernow/articles/1878.aspx "Erno" <nospam> wrote in message news:%23zfhR3OKGHA.1288@TK2MSFTNGP09.phx.gbl... > In a usercontrol I created a toolbar with some checkboxes grouped by > setting a GroupName. everything works fine. > But when I use multiple instances of the usercontrol the group extends > across the usercontrols. > > How do I put these checkboxes in distinct groups without writing some code > that renames these groups on the fly... > > Thanks, > > Erno > ---- > WPF tutorials: http://blogs.infosupport.com/ernow/articles/1878.aspx > > > > |
My System Specs![]() |
| | #3 (permalink) |
| | Re: CheckBox groups I 'solved' it like this (but don't like it): void Viewer_Loaded(object sender, RoutedEventArgs e) { if (this.Name != string.Empty) { foreach (object ctrl in tb.Items) { RadioButton r = ctrl as RadioButton; if (r != null && r.GroupName != string.Empty) { r.GroupName = this.Name + ":" + r.GroupName; } } } } tb is the toolbar. This all depends heavily at having named the usercontrol... Surely there is another way... Erno ---- WPF tutorials: http://blogs.infosupport.com/ernow/articles/1878.aspx "Erno" <nospam> wrote in message news:%23zfhR3OKGHA.1288@TK2MSFTNGP09.phx.gbl... > In a usercontrol I created a toolbar with some checkboxes grouped by > setting a GroupName. everything works fine. > But when I use multiple instances of the usercontrol the group extends > across the usercontrols. > > How do I put these checkboxes in distinct groups without writing some code > that renames these groups on the fly... > > Thanks, > > Erno > ---- > WPF tutorials: http://blogs.infosupport.com/ernow/articles/1878.aspx > > > > |
My System Specs![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| databinding to 3-state checkbox? | .NET General | |||
| Welcome Center - can't get rid of it (checkbox is missing!) | Vista installation & setup | |||
| Welcome Center - can't get rid of it (checkbox is missing!) | Vista General | |||
| Checkbox to never see this pop-up again. | Vista account administration | |||