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
705
how to set initial value but not add to items in a dropdownlist
posted

Hi,

In a comboEditor, I need to set the drowpdownstyle to "drowdownlist", and set the initial text like "please select ..." ( I don't want to add this to the comboEditor's items), then how can I do?

Thank you very much

Wei

Parents
No Data
Reply
  • 469350
    Offline posted

    Hi Wei,

    In DropDownList style, the combo's value has to match an item on the list. If you set Nulable to true, it should accept null, though. So what you probably need to do is set Nullable to true, default the value of the control to null or DBNull.Value and then set the NullTextLabel to the text you want displayed. 

     

Children
No Data