SmartClient Version: SNAPSHOT_v9.0d_2012-11-15/PowerEdition Deployment (built 2012-11-15)
Before I post any code I wanted to know if you may have an explanation for this behavior I'm seeing with the ComboBoxItem widget.
I believe my code is vanilla, we have many instance of ComboBoxItems sprinkled around our code base and all others work, and this one is coded similarly.
This ComboBoxItem has an attached option DataSource.
Clicking inside the box causes the dropdown list to populate with a list of names of files from a simple DataSource.
However one of the 10 returned records (the file names) had a value 'Default'. The box always selected that value, but the getValue() call on the box always returned a null string. The box would display the string 'Default'.
I failed to change this behavior having tried to setDefaultValue() and as many option variations as I could find.
Eventually I simply removed the record from the database that contained the 'Default' file name. No code changes.
The ComboBoxItem now works flawlessly. I can select items from the dropdown and tab and arrow key between choices and override the choices.
I suppose I should go back and add the data record back in and see if the ComboxBox goes back to the failing state.
Are you aware of any such issues?
--> Please ignore this part of the post. The ComboBox is just selecting the first record in the dropdown list. Deleting the 'Default' record just moved the selection to the next in the list.
Before I post any code I wanted to know if you may have an explanation for this behavior I'm seeing with the ComboBoxItem widget.
I believe my code is vanilla, we have many instance of ComboBoxItems sprinkled around our code base and all others work, and this one is coded similarly.
This ComboBoxItem has an attached option DataSource.
Clicking inside the box causes the dropdown list to populate with a list of names of files from a simple DataSource.
However one of the 10 returned records (the file names) had a value 'Default'. The box always selected that value, but the getValue() call on the box always returned a null string. The box would display the string 'Default'.
I failed to change this behavior having tried to setDefaultValue() and as many option variations as I could find.
Eventually I simply removed the record from the database that contained the 'Default' file name. No code changes.
The ComboBoxItem now works flawlessly. I can select items from the dropdown and tab and arrow key between choices and override the choices.
I suppose I should go back and add the data record back in and see if the ComboxBox goes back to the failing state.
Are you aware of any such issues?
--> Please ignore this part of the post. The ComboBox is just selecting the first record in the dropdown list. Deleting the 'Default' record just moved the selection to the next in the list.
Comment