Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1185
UltraComboEditor Defaulting to 0
posted

I am using an UltraComboEditor

The UltraComboEditor is linked to a List<> where the DisplayMember is set to "Description" and the ValueMember is Set to "ID"

the ID is an integer and is stored in the relevant field on the table.

the UltraComboEditor is Styled as a DropDown, Autocompletemode = Suggest, AutosuggestFilterMode = Contains, Limit to List = true.

my problem is that when my form is initialised to edit a new record, where the value for the combo box has not yet been set the text of the combobox has defaulted to "0"

This is a pain as and "0" is not in the List and when the user starts to type, they have to delete the "0"

As a work around I set the UltraComboEditor.Text = "" where UltraComboEditor.Text = "0" in the Value_Changed Event,  (though this will not work if an entry in the list begins with "0"!)

How can I get the UltraComboEditor to initialise to "" (string.empty) instead of "0"? 

Parents
No Data
Reply
  • 9190
    Offline posted

    Hello,

    I will be happy to assist you with this issue.

    I followed the steps you suggested and was unable to reproduce the behavior you're describing.

    I have attached the sample project I used to test this.  Please test this project on your PC; whether or not it works correctly may help indicate the nature of this problem. 

    If the project does not work correctly, this indicates either a problem possibly specific to your environment, or a difference in the DLL versions we are using.  My test was performed using version 11.2.20112.2019 in NetAdvantage for .NET 2011 Volume 2.

    If the project does show the product feature working correctly, this indicates a possible problem in the code of your application.  It will help if you can provide a small, isolated sample application that demonstrates the behavior you are seeing.

    Or, if this sample project is not an accurate demonstration of what you're trying to do, please feel free to modify it and send it back, or send a small sample project of your own if you have one.

    Please let me know if I can provide any further assistance.

     

    utlraComboEditorSample.zip
Children