Hi
I am using field settings CellValuePresenterStyleSelector to provide custom StyleSelector but apparently it is not reevaluated on ItemChanged of the underlying data collection.
Is there a way to force the reevaluation and to force the call to SelectStyle?
Thank you
Hello,
I have reproduced your exact issue. I will need to do a little more research on this because what I have seen from other control vendors and the ms grid view control, this functionality does not seem to be implemented for performance reasons. I will discuss this issue with our developers to see if this is possible.
Also, a style selector may be overkill for what you need. You may be able to get away with a trigger via a style. Please let me know your scenario and I will do my best to help.
Hi Steve
I have looked into the sample and it looks like the events that you mentioned might suffice for solving our current issue at hand.
I would like to ask you though how big performance hit would it be if the StyleSelector Select method is called by your control, because such a solution would be very nice in a long run.
How is it comparable to the performance hit that we would incur if the DataValueChangedDirect or DataValueChanged is raised for every field?
You said that MS GridView control and other vendors are trying to avoid this for performance reasons, but I hear that there are other vendors that also had such concerns but then implemented the behaviour.
Do you think it is feasible that Infragistics would also consider such possibility?
The CellValuePresenterStyleSelector will not do everything that you need. It will not re call the StyleSelector class to re evaluate the style of the cellValuepresenter on value changes. However, I have a little workaround that will help you out. You can handle these two events, DataValueChangedDirect and CellUpdated to handle when the source changes(DataValueChanged) and when the user updates the cell(CellUpdated) and you can change the style of the CellValuePresenter directly right there. I have attached a sample that demonstrates this. Please take a look.