Please help check following example:
<igDP:UnboundField Column="1" Row="2" ColumnSpan="5" Name="up" Visibility="{Binding Path=Record, Converter={infragisticsXamlGridProj1:NumberToVisibilityConverter2}}"> <igDP:UnboundField.Settings> <igDP:FieldSettings CellContentAlignment="ValueOnly" CellValuePresenterStyle="{StaticResource rowDetailsStyle_1}" AllowRecordFiltering="False" /> </igDP:UnboundField.Settings> </igDP:UnboundField>
In the converter class NumberToVisibilityConverter2 I want to get the object of the data row but I can't get that. please help how to specify the Path.
thanks,
Eric
Hello Eric,
Thank you for your post!
I have been looking into your issue. The Fields and UnboundFields does not derive from Framework element and they does not expose a DataContext property. This is why the bindings for the Visibility property would not work. What I can suggest is to take a look at the following link to our forum, where a similar issue is discussed: http://www.infragistics.com/community/forums/p/78723/431032.aspx. On this thread you can find a sample application too.
Please do not hesitate to let me know if you have any further questions on this matter.
Hi,
This example doesn't meet my requirement. It binds to the DataContext object but I want binding to the data row object. Do you guys have any ideas on this?
thanks,Eric
I have been looking into your post and it seems that I am missing something from your scenario. Would you please provide me with some further information about the functionality you want to achieve? Also to which record do you want to bind the visibility of the field, mentioned in your fist post?
Thank you for the provided information. Looking forward to hearing from you.
I am just checking it you have any further questions on this matter. Please do not hesitate to let me know if you do.
Try
<igDP:UnboundField Binding="{Binding Path=Cell.Record.DataItem, RelativeSource={RelativeSource Self}}">Bye