Thanks for your reply.
My scenario is the following:
I have a button which represents a bookmark button, when presed the item is added to bookmarks.
In my view model I have a property IsBookmarked with the following setter:
success = DataAccess.AddToFavorites(
) _IsBookmarked =
_IsBookmarked = value;
In the method AddToFavorites I check if more than 100 bookmarks are added, if yes then this item is not bookmarked and the return value is false.
The IsBookmarked property is TwoWay bound to the IsChecked property of the ImageButton. When I set the property to false in the setter, the image of the button still changes like its set to true.
I have tried using a converter which always returned false (for testing) in both Convert, and ConvertBack methods, but after the button is pressed the Image still changed, and this is my problem. I need something like a Checking event, in which I can call e.Cancel = true.