Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > Avalon

Vista - Does the dependency property inheritance mechanism only work between class and subclasses ?

 
 
Old 11-29-2006   #1 (permalink)
Pon


 
 

Does the dependency property inheritance mechanism only work between class and subclasses ?

Does the dependency property inheritance mechanism only work between class
and subclasses ?
I mean if i want a dp for a class A object can inherit its value from a
class B parent (in the logical tree) object, does it necesseraly imply that
class A and class B are subclasses of the class that registers the dp ?
If not, how can I do that ?



My System SpecsSystem Spec
Old 11-29-2006   #2 (permalink)
Douglas Stockwell


 
 

Re: Does the dependency property inheritance mechanism only work between class and subclasses ?

When you register the DP you can specify additional metadata. See the
Inherits property of FrameworkPropertyMetadata.

- Doug

"Pon" <pongla.public@laposte.net> wrote in message
news:uJtO1o5EHHA.2452@TK2MSFTNGP06.phx.gbl...
> Does the dependency property inheritance mechanism only work between class
> and subclasses ?
> I mean if i want a dp for a class A object can inherit its value from a
> class B parent (in the logical tree) object, does it necesseraly imply
> that class A and class B are subclasses of the class that registers the dp
> ?
> If not, how can I do that ?
>


My System SpecsSystem Spec
Old 12-03-2006   #3 (permalink)
Pon


 
 

Re: Does the dependency property inheritance mechanism only work between class and subclasses ?

Thanx a lot.


"Douglas Stockwell" <doug@remove.11011.net> wrote in message
news:9EAE4705-07C9-48CF-ACDE-8191D169541F@microsoft.com...
> When you register the DP you can specify additional metadata. See the
> Inherits property of FrameworkPropertyMetadata.
>
> - Doug
>
> "Pon" <pongla.public@laposte.net> wrote in message
> news:uJtO1o5EHHA.2452@TK2MSFTNGP06.phx.gbl...
>> Does the dependency property inheritance mechanism only work between
>> class and subclasses ?
>> I mean if i want a dp for a class A object can inherit its value from a
>> class B parent (in the logical tree) object, does it necesseraly imply
>> that class A and class B are subclasses of the class that registers the
>> dp ?
>> If not, how can I do that ?
>>

>



My System SpecsSystem Spec
 

Thread Tools


Similar Threads
Thread Forum
WPF: Autogenerate a Private Dependency Property ? .NET General


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46