-
- kritzelkratz
- Posts: 18
- Joined:
ComboBox: strange behaviour when adding items
we are programmatically adding ComboBoxes to e.g. a StackPanel.
since noesisgui version 1.1.6 the items are displayed twice.
we narrowed it down to it being necessary that the items need to be added to the ComboBox before the ComboBox is added to e.g. the StackPanel.
but we need to fill the ComboBox after it has been added to the layout. which has worked before 1.1.6.
is this a bug, or did we do something wrong the whole time?
this doesn't work: (the combobox popup shows "test1 test2 test3 test1 test2 test3", but the combobox item count is 3)
StackPanel sp = FindName<StackPanel>("mainPanel");
ComboBox cb = new ComboBox();
sp.GetChildren().Add(cb);
cb.GetItems().Add("test1");
cb.GetItems().Add("test2");
cb.GetItems().Add("test3");
and this works: (the combobox popup shows "test1 test2 test3")
StackPanel sp = FindName<StackPanel>("mainPanel");
ComboBox cb = new ComboBox();
cb.GetItems().Add("test1");
cb.GetItems().Add("test2");
cb.GetItems().Add("test3");
sp.GetChildren().Add(cb);
since noesisgui version 1.1.6 the items are displayed twice.
we narrowed it down to it being necessary that the items need to be added to the ComboBox before the ComboBox is added to e.g. the StackPanel.
but we need to fill the ComboBox after it has been added to the layout. which has worked before 1.1.6.
is this a bug, or did we do something wrong the whole time?
this doesn't work: (the combobox popup shows "test1 test2 test3 test1 test2 test3", but the combobox item count is 3)
StackPanel sp = FindName<StackPanel>("mainPanel");
ComboBox cb = new ComboBox();
sp.GetChildren().Add(cb);
cb.GetItems().Add("test1");
cb.GetItems().Add("test2");
cb.GetItems().Add("test3");
and this works: (the combobox popup shows "test1 test2 test3")
StackPanel sp = FindName<StackPanel>("mainPanel");
ComboBox cb = new ComboBox();
cb.GetItems().Add("test1");
cb.GetItems().Add("test2");
cb.GetItems().Add("test3");
sp.GetChildren().Add(cb);
-
-
sfernandez
Site Admin
- Posts: 3222
- Joined:
Re: ComboBox: strange behaviour when adding items
This is totally a bug (I was able to reproduce it), please report it in the bugtracker. We will fix it for the next release, or provide you a hotfix as soon as possible.
Sorry for the inconvenience.
Sorry for the inconvenience.
-
- kritzelkratz
- Posts: 18
- Joined:
Re: ComboBox: strange behaviour when adding items
i reported the bug on the bugtracker.
a hotfix would be really really nice, of course.
a hotfix would be really really nice, of course.

-
-
sfernandez
Site Admin
- Posts: 3222
- Joined:
Re: ComboBox: strange behaviour when adding items
Thanks, I'll notify you about the status of this issue in the bugtracker.
-
- golgepapaz
- Posts: 43
- Joined:
Re: ComboBox: strange behaviour when adding items
Same thing happens with treeview items also. I had to delay going into 1.1.7 . Still using 1.1.5
-
-
sfernandez
Site Admin
- Posts: 3222
- Joined:
Re: ComboBox: strange behaviour when adding items
We fixed this issue and will be solved for the next release.
Please take a look at your private messages, I sent you one a moment ago.
Please take a look at your private messages, I sent you one a moment ago.
Who is online
Users browsing this forum: Ahrefs [Bot], Google [Bot], Semrush [Bot] and 3 guests