>Oscar,
>
>>The problem is that some events like Refresh (triggered by activate), check if the business object has changed. MM uses the GetNextModified function in order to check for changes on a cursor with buffer mode 5, and this function funds out somehow that a record has been modified regardless of the field state been set to non-modified.
>
>There is an "issue" with VFP where GETNEXTMODIFIED() ignores the fact that you've set a field to "unchanged". Probably the cleanest way around this is to override the business object's IsChanged() method. You could have it run the default code, and if DODEFAULT() returns True, do an additional check to see if the only fields that have changed are your custom fields.
>
>Regards,
Hi Kevin,
We hit the same problem today. We have a very complex form with multiple pages and lots of hierarchical biz objects. We have parent record and an empty child record. The child is table buffered. When we invoke the form's Save() method, getNextModified returns -1, because we have a new empty record. However, there were no changes for this record, so IsChanged in this case should return .f. and don't try to save this completely empty record. What can we do about it?
Thanks in advance.
If it's not broken, fix it until it is.
My Blog