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
40
Setting a default value within an ultradropdown within an ultragrid
posted

I am working on a solution to default a value on load of a certain presenter.  The logic appears to be working (and worked previously with infragistics controls version 10.3 prior to upgrading to 12.3).

The data values are correctly bound and logic in the existing loop functions correctly.  The .SelectRow updates the index correctly but does not reflect the changes on the UI side.  Afterwards the ultragrid is updated to reflect the changes from the dropdown box.  Am I missing something here?  I've tried everything I can think of

code:

// Set default value
for (int i = 0; i < ratecards.Count; i++)
{
     if (ratecards[i].WrappedObject.IsDefault && _presenter.IsRatecardValid(ratecards[i]))
     {
          _ddRatecardArray[row].SelectedRow = _ddRatecardArray[row].Rows[i];
          break;
      }
}


e.Row.Cells[Properties.Resources.PlanHeaderRatecardCol].ValueList = _ddRatecardArray[row];

[row] is set to 0 as there is an array of ultradropdown boxes per each row of the ultragrid

[properties....] is an abbreviation for the correct column in the ultragrid as well.

Thanks!

Parents
No Data
Reply
  • 23930
    Offline posted

    Hi Kevin,

    Thank you for contacting Infragistics Developer Support.

    From your description, it seems that you are trying to set the default selected row in an UltraDropDown by setting .SelectedRow property. You can do this in the after drop down event of the UltraDropDown.

    If I have misunderstood your scenario, please provide me with simplified working sample demonstrating your issue. I will be glad to assist you further once I have the sample.

    I am looking forward to your reply.

Children
No Data