1
I need to create checklists that depend on previous inputs and processing. How do I create these "checklists" dynamically in WPF? (a code snippet, please).
1
I need to create checklists that depend on previous inputs and processing. How do I create these "checklists" dynamically in WPF? (a code snippet, please).
2
CheckBox ch1 = new CheckBox();
ch1.Location = new Point(10, 10);
ch1.Text = "Olá Mundo!";
this.Controls.Add(ch1);
See if you solve, also enter your default options, for example if you want it to come checked already, etc.
Browser other questions tagged c# .net wpf
You are not signed in. Login or sign up in order to post.
I’m not finding a method that fits with
this.Controls.Add(ch1)
– Paulo
this is the name of the form you are in, in which case the row adds the component in this form.It appears that error?
– rods
The Controls class is not available from "this" (I had already read something similar in another topic, but I think this class is only from windows Forms).
– Paulo
try adding a panel and adding inside it panelnome.Children.Add(ch1);
– rods
Ok. It worked. I hope the panel expands depending on the number of checklists.
– Paulo
anything comments there that we try to solve ^^
– rods