Hello,
I#m using XamDataGrid for WPF now for a couple of years and I must say, if you know how to do things, it's pretty awesome.
But this one I struggle:
I have grid which contains a couple of columns and the first one is unbound. Basically, I have a custom CellValuePresenterStyle and I'm showing a button for a special action on this row. That's working very good.
On the second I have a normal field and I have set IsScrollTipField = true and I get this error message:
"The Field cannot be made the 'ScrollTipField' unless it is contained in the Fields collection of the Owner."
I don't understand what it's trying to tell me? What's the issue? How to solve it?
Here for better understand my two columns as source code:
<ig:Field BindingType="Unbound" Width="18" FixedLocation="FixedToNearEdge"> <ig:Field.CellValuePresenterStyle> <Style TargetType="{x:Type ig:CellValuePresenter}"> <Setter Property="Template"> <Setter.Value> <ControlTemplate> <Button Height="16" Width="16" Click="Print_Clicked" IsEnabled="{Binding DataItem.IsPrintable}"> <Image Source="/ISD.PRINCE;component/Images/Printer.png" /> </Button> </ControlTemplate> </Setter.Value> </Setter> </Style> </ig:Field.CellValuePresenterStyle></ig:Field><ig:Field Name="WO" Label="{isd:Translation Key=Common.WorkOrder}" FixedLocation="FixedToNearEdge" IsScrollTipField="True"/>
Niko,
This was logged as development issue 241479 and that fix was included in the October 2017 service release which is the last service release for 2016 Volume 2. The specific version of the service release is 16.2.20162.2237 so if you are using an earlier version of 2016 Volume 2, I recommend that you get the latest service release from the my keys and downloads page.
Hello Ditmar,
I see the very same problem with WPF 16.2 and VS 2017.
<igDP:XamDataGrid.FieldLayouts> <igDP:FieldLayout>
<!-- there a number of other fields, summaries etc.-->
<igDP:Field Label="Baustelle" Name="BaustellenBezeichnung" IsReadOnly="True" AllowEdit="False" DisallowModificationViaClipboard="True" IsScrollTipField="True" Width="Auto" />
I don't understand how a field that is listed in FieldLayout cannot not be part of the FieldCollection.
The errors goes away when I close the XAML designer window.
Are there any news on this subject?
Thanks
Niko
Hi Timon,
Thank you for the reply.
I have created the private case (CAS-186491-X9X1T5) and you can view it from the following link:
https://es.infragistics.com/my-account/support-activity
You can provide me with the sample through the case itself.
I am looking forward to hearing from you.
Hi Dimitar,
thanks for your answer and opperunity to send you the code privatly which I like to use.
Please give me instructions how you send you our source code and after we found a solution, I'll post it here on the forum, so everybody has the solution.
Thanks!
Unfortunately, I believe it would be very difficult for you to debug this issue on your side. It would require you to build the XamDataGrid source code and open two instances of Visual Studio – one with your application, the other attached to the first one and with the XamDataGrid source code loaded. It would be a lot better if you can provide us with an application that reproduces the issue. One way to do this is if you start with your real application and remove all the unnecessary to reproduce the issue parts. I can open a ticket for you in our system, if privacy is a concern.
Another option is to work around this by setting the IsPrimary property to true, instead of setting IsScrollTipField property on the field. If no field is set to be a scroll tip field, the primary field will be used instead and it can be set explicitly with the help of the IsPrimary property. Note that this may have side effects, like highlighting, if you have set the HighlightPrimaryField property, but other than that setting the IsPrimary property will have the same effect as setting the IsScrollTipField one. For more information on this, please follow this link:
http://help.infragistics.com/Help/Doc/WPF/2011.2/CLR4.0/html/InfragisticsWPF4.DataPresenter.v11.2~Infragistics.Windows.DataPresenter.Field~IsScrollTipField.html