Is there a way to make Tab and Enter both commit the currently selected value?
Thanks,
Jon
Hi Jon,
Maybe it's because we are using different versions of the Infragistics DLLs but when I tested this against the latest 14.2 WPF DLLs I was not able to reproduce this. In my sample if I start typing values into the combo editor text box, it filters the dropdown values as expected. If I then press the Tab key to move focus away from the combo editor and into a different control, I can see that the first value in the filtered dropdown is selected. Both the SelectedItem and SelectedValue (assuming I set SelectedValuePath) properties have updated. I have attached my sample. Are my steps wrong? Or are you using an older version? If so can you tell me what the exact version # is of the DLLs you are using?
Sorry I didn't give more information. I am on 14.2.
The issue is only if I have CustomValueEnteredAction="Allow". I would like tab in some cases to commit the selected record.
Thanks.
My DLLs are 14.2.20142.1000.
Here is a link to my files:
http://1drv.ms/1xCAxkk
I have attached a screen video of what I'm trying to do with a sample project.
In the Attribute 1 column, I type in 1.5 and click Enter. Value is committed as expected.
In the Attribute 2 column, I type in 1.5 and click Tab. Value is lost.
In the Attribute 3 column, I type in 1.5 and click outside the cell. Value is lost.
These are the scenarios I need to have the value committed.
Also, as you can see from the video, there is a secondary issue with the popup. As I'm typing sometimes the footer does not render properly. You see the blue line that shows up. All I'm doing is showing the footer only when all items have been filtered out.
Let me know if you have any more questions for me. Thank you so much for your time.
Is that the right link? When I go to it, it opens an excel file called starting_new_budget_template_new.
Here is the correct link.
http://1drv.ms/1OD456A
Thanks. I can see the behavior you described in the sample. I'm looking into this.
The editor's value was not getting set for some reason so I modified the code to handle the combo editor's SelectionChanged event. This event is firing when you press Enter/Tab or click away from the editor when there is text in the combo editor (since the "Add" modifier is on). Once a selection is made I am getting the cell and setting it's Value directly. One thing I'm confused about is the way that you are setting the DropDownValues collection. The code is currently setting this every time edit mode is started on the cell so I would think that any additions you add to the dropdown list would be lost when you entered edit mode on that cell again. Wouldn't you want to persist the collection rather than resetting it constantly?
Thanks for getting back to me.
I haven't looked at your sample yet, but to answer your question:
DropDownValues is created based on what the values are in other columns, so it needs to be recreated whenever a value changes anywhere in the row. So I suppose I could persist it and try to be smarter about when the other values are dirty, but even then I would need one for each cell, so having those always ready would increase my program's memory footprint. I am just adding them to the collection so it is a valid selection that gets sent back to the textbox mode when the cell is not in edit mode, so if you have a better solution for that I am all ears.
Thanks for explaining that. It makes sense that you would have to reassign the ItemsSource if the values in it are dependent on other columns. I'm not sure how you plan to handle persisting newly added items though. For example if I type in 1.5 and then tab to the next column but then go back to the previous column and enter edit mode again, I would expect to still see 1.5 in the dropdown list since that's what CustomValueEnteredAction="Add" would do. Unless you just need that setting to allow users to type whatever they want into the textbox and not actually need the value to be persisted. In which case then forget everything I was confused about.
If they type in 1.5 and then come back into edit mode, when XamMultiColumnComboEditor calls Loaded, I pipe the text into the SpecializedTextBox for the XamMultiColumnComboEditor editor.
As for your sample, I see things working correctly in the sample and now I need to get it working properly in my real project.
Were you able to find out what was going on with the weird blue box that would show up in the popup when typing when a footer is present?
I am unable to find where this blue bar is coming from. It doesn't appear to be a component of the dropdown since I can't find anything for it in the Visual Tree. I was able to reproduce this outside of your sample so it appears to be an issue with the comboeditor when you set the Footer. As a result of this, I logged a development issue so that our development staff can examine this further. The development issue ID is 192201.
In order for you to view the status of this development issue I have opened up a private support case under your account. The case number is CAS-152594-B4M5B5. You can view it here: https://www.infragistics.com/my-account/support-activity