Hi I have an issue where I am trying to retrieve the text of the dropdownitem which was selected in a dropdownprovider once a postback occurs (via a submit button on the form).
I can't put the text in the value of the dropdown either since I need to have related data (which gets parsed and populated to other columns on client events) for the value. For example, I have my dropdownprovider which has PC Types in it and the Text is the description of PCs while the value is the breakout of costs in a delimited string which I split and send to other columns during the SelectionChanged client event of the dropdownprovider. Is there a way to set the Text of that column so that it is retrieved once posted back?
I tried to do something like this PCTypeCell = arg._cell._row.get_cell("PCType"); (on Grid Entered Edit) and then PCTypeCell.set_text(sender.get_activeItem().get_text()); (on dropdownprovider SelectionChanged). This still doesn't seem to force the column to have the text value once the form is posted back.
Is there anyway that I can retrieve just the text of the selected item during postback when looping through grid.Rows to update my data? row.Items.FindItemByKey("PCType").Text always seems to get the value of the selectedItem from the dropdownprovider.
Hello Patrick,
Thank you for contacting Infragistics!
I have some follow up questions concerning this matter. How do you have your DropDownProvider setup? Do you bind to different fields for the TextField and ValueField properties? How are your grid and columns setup?
Thank you for responding.
I was able to work around this issue by including the Textvalue as part of the delimited valuefield and then checking for the delimiter when I postback and save the data. If the delimiter is there then I split it and use the string at index 0 (the Textvalue) if the delimiter isn't there then I just take the "text" of the field.