CustomField not updating value or datasource

I have created a custom field by extending “CustomField” and everything is working fine, except for one major issue. I can attach a “PropertyDataSource” using “setPropertyDataSource” and the value of the field is set to the value of the property specified. But when my field changes it’s “InternalValue” or it’s “value” and I then query those values from the container holding the new custom field I built, I do not get the new values, instead I get the old values. I have even tried setting “immediate” to true, to see if that help.

I was able to get set the value by getting the “PropertyDataSource” and setting the value manually, but I would think that step would of been handled in th the “setInternalValue” or “setValue” of the “CustomField” class.

Attached is the code that I used, but because of independencies (mainly dealing with webservices) involved I did not attached the whole project.

Thank you (9.27 KB)

to update value of a Field to PropertyDataSource, you can either call commit() on the Field, or setBuffered(false) on the PropertyDataSource

I tried the commit() and it set the field back to the value that was in the PropertyDataSource before hand. I did not try the setBuffered(false) on the PropertyDataSource.

My issue is not really how to get it to work, but more about why my values were not updated when I called “setInternalValue” or “setValue” on the CustomField. It would seem to me that one or both of them would update the datasource and value that was returned when I query value. Especially since that code from what I can tell is running on the server. It is not like I am updating on the client and then having to wait for the data to get passed back to the server.

So either I am not doing something right (most likely) or there is a bug that needs to be addressed.