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
45
Select a cell's text in ValueList
posted

Hi

I use a ValueList (and I set the type of the column to DropDownList) to display a selection of different values in a grid. My problem is that when the user clicks the cell at the first time when the page has been refreshed the first value in the ValueList is selected but I want to select the value or text that is stored in the cell.

  • 8680
    posted

    If I understand you correctly, what you're asking for is the way a dropdown column is suppose to work.  But DropDown columns are tricky. There are a number of gotcha's lurking in those woods.

    In the past, I've solved dropdown problems by checking:

    • Is the column.ColumnType set to DropDownList?
    • Do the data types match?  Datatypes for the underlying row data (in your database) need to match those in the database data destined for the dropdown's ValueList.ValueMember. In the grid, the UltraGridColumn.DataType must also match.
    • Do the column names match?  (In all the same places.)

    HTH