Assume two controls:
<ParentControl ToolTip="{GIMME ChildControl.ToolTip}">
<ChildControl ToolTip="Yay! Look at me! I'm bouncing off walls!!!"/>
</ParentControl>
It’s the {GIMME ChildControl.ToolTip} I’m not sure about. I have an inkling it won’t work (what is a GIMME anyway), but I’m kind of failing here.
Things I have considered:
{Binding RelativeSource=???}– but won’t that look in the bound data? I want to reference the child control, not something in the bound data{StaticRecourse useSameForChildControl}– except I’m setting theToolTipproperty dynamically in the child control…
Ugly solution that will definitely work – give ChildControl a
x:Namevalue, then bind{Binding ElementName=childElemName, Path=ToolTip}.(Made into an answer as suggested ;))