>>>>Even with that fix the method I used in my code to set the property will still set it to false and since that's the same call xaml uses, so will the xaml. The only work around I know for that is to make ContentIsLocked readonly, but then you won't be able to set it from xaml :-(
>>>
>>>AFAICS the only place to trap and handle this is in the Coerce callback. But I was still confused as to the result of returning DependencyProperty.UnSetValue from this. I now see that this just leaves the old value in place rather than being the equivalent of .ClearValue() which is what I need. But so far I don't see how I can achieve the latter within the callback method .......
>>>Best,
>>>Viv
>>
>>Unfortunately... I wasn't able to find a good solution for this.
>>
>>I may try some more tonight, but so far no joy.
>
>Can't find a solution either :-{
>Maybe I need to rethink the approach......
What I tried was using 2 DPs
ContentIsLocked - Normal Attached DP no inheritance.
ContentLock - ReadOnly Attached DP with inheritance.
The idea was to use the ReadOnly DP in CoerceIsLocked to return the correct value.
But I couldn't seem to get a readonly DP to support inheritance so it didn't work. :(