Hmmm. It turns out CanCancelEdit is set to false in the EditableCollectionView, 
which means that 
when CancelEdit is called, it simply returns without clearing the errors.

The EditableCollectionView is a PagedCollectionView. Not sure yet how I can 
make it so that the 
CanCancelEdit can be changed to true.


On Thu, Feb 18th, 2010 at 4:49 PM, [email protected] wrote:

> Hi,
> 
> I am having a problem cancelling a data form. 
> 
> Basically, I am displaying a dataform after calling AddNewItem() on
> the dataform.
> 
> Then I click Next, which fires ValidateItem(). Of course, with no
> values set, it fires a number of 
> validations. Then I click Cancel, which callse CancelEdit() on the
> dataform. 
> 
> The line after I call cancel, I try to set the CurrentItem on the
> DataForm to null. It causes an 
> exception: "Cannot change currency when an item has validation errors
> or it is being edited and 
> AutoCommit is false".
> 
> I believe the item has validation errors, but surely they should have
> been cleared by the 
> CancelEdit?
> 
> How would I get around this to drop the item?
> 
> Regards,
> Tony
> 
> _______________________________________________
> ozsilverlight mailing list
> [email protected]
> http://prdlxvm0001.codify.net/mailman/listinfo/ozsilverlight
> 
> 
> 



_______________________________________________
ozsilverlight mailing list
[email protected]
http://prdlxvm0001.codify.net/mailman/listinfo/ozsilverlight

Reply via email to