combobox

Bound combobox items refers to different field items

血红的双手。 提交于 2019-12-17 21:34:54
问题 I got a bounded combobox to a group name in vb.net. i can view in the drop down items of the combobox the set of GROUP NAMES. but when i do an insert or update query, i need to make the selected group name refers to the GROUP NUMBER. I don't want to store letters in the database, instead i prefer numbers. how can i do that?! Here is my code so far : cmd1.Parameters.AddWithValue("@group", DirectCast(Additemcombobox.SelectedItem, DataRowView).Item("GroupName")) Storing the group name in

Winforms Combobox SelectedValue is Null

半腔热情 提交于 2019-12-17 21:30:58
问题 I have a data entry form that had several comboboxes on it. Each of the combo boxes has its own binding source and it is populating correctly when I launch the form. However, if I edit the record on the form and try to pass to the database the updated selectedvalue from the combobox I get an error that the value I am passing it NULL. This issue seems to happen every other time I run the darn thing and I can't figure out why it is not working properly. Basically I am trying to insert a new

How use the combobox keydown event without selecting the listed item

喜你入骨 提交于 2019-12-17 19:56:07
问题 I have in my Excel VBA project, a combobox which uses a range of cells as it's list of items. I have used a filter in it, so that whenever a value is entered, the list shrinks down to the items containing the string, and dropdown list is shown. However, the problem appears, when the dropdown is shown, the navigation keys can't be used to scroll within the items. As soon as the down key is pressed the dropdown list will be filtered again. I guess its happening because the down key while

Combo box drop down width on suggest

╄→尐↘猪︶ㄣ 提交于 2019-12-17 19:37:08
问题 I have a form which has a Combo Box Control. I have selected the drop down style property to DropDown. I have also set the DropDown Width to 250. I have set the auto complete mode to suggest and the auto complete source to listitems. it works absolutely fine when i click on the drop down. but when i type in somethin, the auto complete mode activates a drop down which has a small width. any help appreciate. i wanna know how to increase the width of the auto complete drop down via code so that

WPF DataGridTemplateColumn with ComboBox Binding (MVVM pattern)

坚强是说给别人听的谎言 提交于 2019-12-17 19:09:26
问题 I'm going bonkers with the following WPF DataGrid+ComboBox scenario. I have a set of classes which look like; class Owner { int ID { get; } string Name { get; } public override ToString() { return this.Name; } } class House { int ID { get; } Owner HouseOwner { get; set; } } class ViewModel { ObservableCollection<Owner> Owners; ObservableCollection<House> Houses } Now my desired outcome is a DataGrid which shows a list of rows of type House , and in one of the columns, is a ComboBox which

Simple WPF combobox filter

半世苍凉 提交于 2019-12-17 19:07:08
问题 I have searched Google for a simple solution to this but no luck. I have a standard WPF combo box which I would simply like to be able to filter the list displayed according to the first 2 or 3 letters a users types when the combo box has focus. I tried some coding including some lamba expressions but the error "System.NotSupportedException" keeps getting thrown on the line where "combobox.Items.Filter" is specified. I'm not using MVVM and would just like this simple functionality available

Javafx combobox with custom object displays object address though custom cell factory is used

柔情痞子 提交于 2019-12-17 18:49:11
问题 I have a combobox which shows list of User objects. I have coded a custom cell factory for the combobox: @FXML ComboBox<User> cmbUserIds; cmbUserIds.setCellFactory(new Callback<ListView<User>,ListCell<User>>(){ @Override public ListCell<User> call(ListView<User> l){ return new ListCell<User>(){ @Override protected void updateItem(Useritem, boolean empty) { super.updateItem(item, empty); if (item == null || empty) { setGraphic(null); } else { setText(item.getId()+" "+item.getName()); } } } ; }

Is there any difference between drop down box and combo box?

断了今生、忘了曾经 提交于 2019-12-17 18:48:15
问题 Is there any difference between drop down box and combo box [ HTML ]? Actually the point is, everytime i say something like: " there is some problem with the combo box ", my senior says: " that's not a combo box that is a drop down ", :) 回答1: Technically, there are no combo boxes in HTML, because the <SELECT> can't be typed into. See the Wikipedia article on Combo Box (emphasis mine): A combo box is a commonly-used graphical user interface widget. It is a combination of a drop-down list or

EXTJS 4 render HTML of a selected value in a combobox

穿精又带淫゛_ 提交于 2019-12-17 18:43:56
问题 Hello I have the next problem, I want to render the html of my display value in a combobox, at the moment I load a store with the html ready, it renders the html when I show all of them, but when I select one, it show the html. What can I do to render the html when the item is already selected? Here are some images to help to explain the inconvenient: This is when Im going to select one http://i.stack.imgur.com/TcfRA.jpg This is when I select one http://i.stack.imgur.com/Kzi9r.jpg The Html

C# WPF IsEnabled using multiple bindings?

流过昼夜 提交于 2019-12-17 18:14:45
问题 I have a WPF xaml file describing a section of a GUI and I'd like the enabling/disabling of a particular control to be dependent on two others. The code looks something like this at the moment: <ComboBox Name="MyComboBox" IsEnabled="{Binding ElementName=SomeCheckBox, Path=IsChecked}"/> But I'd like it to be dependant on another checkbox as well so something like: <ComboBox Name="MyComboBox" IsEnabled="{Binding ElementName=SomeCheckBox&AnotherCheckbox, Path=IsChecked}"/> What's the best way to