I can't figure out what I'm doing wrong.
I have a TreeView with CheckBox mode set to True and with nothing but Parent Nodes. After checking the first node and a few other random ones I want to loop through this TreeView, and Remove all nodes except the one at Index 0.
Here's my code. A slight variation of it does work to set the Node-Checkbox-Values to False but not to Remove the same.
For Each ctl As TreeNode In TreeView1.Nodes
If ctl.Index <> 0 And ctl.Checked = True Then