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
885
Using ValueListResolved
posted

I have a UltraGrid which has several columns with UltraDropDown controls set as the ValueList.

These columns are ID fields. As an example, one dropdown contains for an ID, an Order #, a Customer name, and a Delivery Date. DisplayMember is Order # and Valuemember is ID, Customer name and Delivery Date are shown when the dropdown is open.

This grid has several unbound columns. Continuing my example, one of these unbound columns is Customer.

I would like to retrieve the value in the Customer column from the dropdown row which matches the underlying OrderID (the Order# from this row is displayed on the grid) and display it in the unbound Customer column, both when the grid is loaded and also when a row is added.

I think this is possible, and supported by ValueListResolved but the documentation on using it is scant and none of the examples I have found are clear enough for me to grasp what I need to do here.

I could create database columns and just store the information directly but that would denormalize the database and doesn't seem necessary.

Can I get some clues, please?

Parents
No Data
Reply
  • 48586
    posted

    Hello,

     

    In AfterCellUpdate even of UltraGrid, you could cast ValueListResolved property of the UltragridCell object, to UltraCombo and then to get underling data row of the current selected value using SelectedRow.ListObject property. Once you have the underlying data row you could update your unbound column with needed value from this row. I have created a small sample in order to demonstrate you this approach. Please run the sample and let me know if this is what you are looking for.

     

    Please let me know if you have any further questions.

    92990.zip
Children