Hi,Could you give me please any hint how outdated values could be displayed in an UltraComboEditor or UltraCombo respectively.Here's the scenario:First we have a catalogue table which will be the DataSource for the ValueList, let's assume it contains job descriptions and has the columns primkey, deletedate and name, e.g:primkey | deletedate | name1 | null | development2 | null | support3 | null | quality managementSecond we have a table which contains the data to display, in this example we'll call it 'staff' and it has the columns primkey, fk_job_description and last_name, e.g.1 | 3 | McOntactus2 | 1 | HeijlsbergThe data is held by a DataSet with two DataTables which are filled by the commands -SELECT primkey, name FROM job_descriptions WHERE deletedate IS NULL -SELECT fk_job_description FROM staff WHERE primkey = 1and each DataTable ist linked to a BindingSource.The UltraComboEditor value property is bound to the fk_job_description column of the staff table via a BindingSource. The DataSource is set to the BindingSource which is linked to the job_description table and the DisplayValue is set to 'name' and the ValueMember is set to 'primkey'.So far everything works fine and selecting a job description is great!Then, one day, a very important person decides that quality management isn't necessary anymore and it is deleted by settng the deletedate. The corresponding record now reads 3 | 2011-11-20 | quality managementand so for our poor Mr. McOntactus the job description now reads like '3' instead of 'quality management'I'd like to have, that the job description lookup still has the text 'quality management', but that item isn't available in the value list anymore.In other words: the old outdated value is kept and displayed in human readable text, but selecting outdated values isn't possible any longer when theTHIA,
Roman
Hi Roman,
Obviously, you cannot remove item 3 from the ValueList in your example, since you still need it to translate 3 into "quality management".
What I would do is use UltraCombo, instead of UltraComboEditor and then you can either hide row 3 or disable it. That way, it's still on the list and the control can translate the DataValue into the DisplayText, but the user cannot choose that item in the future.
Hi Mike,
Mike Saltzman"] What I would do is use UltraCombo, instead of UltraComboEditor and then you can either hide row 3 or disable it. That way, it's still on the list and the control can translate the DataValue into the DisplayText, but the user cannot choose that item in the future.
Your solution works perfectly for me. The effect can be tested, when a valid, but filtered out ValueMember value is entered. Then the UltraCombo translates that value into a human readable Text but that item doesn't appear in the DropDown, neither when dropped down, nor when auto-completing.
The only disadvantage might be, that perhaps much data is loaded into the catalogue table which would never be needed. Might there be another way, like joining the catalogue table by SQL and then set the DataBinding to something else but Value <-> fk_job_description? As I mentioned above: your solution works for me, this question is somewhat more academic...
Thanks,