Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.

DataBinding issue from datagrid

Skip to first unread message


May 15, 2009, 12:01:02 PM5/15/09
<Style TargetType="{x:Type xcdg:DataCell}">
<Setter Property="ReadOnly" Value="False" />
<Setter Property="Background" Value="White" />
<DataTrigger Value="True" >
<MultiBinding Converter="{StaticResource equalsConverter}">
<Binding RelativeSource="{RelativeSource FindAncestor,
AncestorType={x:Type local:TuneOil}}" Path="BubblePointPressureTB"
diag:PresentationTraceSources.TraceLevel="High" />
<Binding Path="OilPvtBubPtPres"
diag:PresentationTraceSources.TraceLevel="High" />
<Binding RelativeSource="{RelativeSource Self}"
Path="ParentColumn.Index" diag:PresentationTraceSources.TraceLevel="High" />
<Setter Property="ReadOnly" Value="True" />
<Setter Property="Background" Value="AliceBlue" />

I have this DataTrigger on a Datacell. I cannot seem to get the first
Binding correct to send the data to the MultiBinding Converter. The first
Binding is trying to get data from this Window called TuneOil and get data
from the BubblePointPressureTB. i can't get it.

I have also tried to Name this Window x:Name="PVTTuningScreen" and have used
it as an ElementName to get to either the TextBox or a Property in the code
behind. I can't get that to work either. the other two bindings work fine.
I even tried using an ElementName="PVTTuningScreen" and set the Path to a
DependencyProperty but that doesn't work either. It doesn't get the real
data. Can someone suggest anything I can do?



0 new messages