Current filter:
                                You should refresh the page.
                                Support Center
                                1
                                  • I also want to have tooltip for each cell in our group. In the datasource, there are two columns: Name and Category. I would like to show Name in one column, and show Category as tooltip. Follow your sample code, I have the following definition:


                                    <dxg:GridColumn FieldName="Name" Header="Name" ReadOnly="True">

                                    <dxg:GridColumn.CellTemplate>

                                    <DataTemplate>

                                    <dxe:TextEdit x:Name="PART_Editor">

                                    <ToolTipService.ToolTip>

                                    <ToolTip>

                                    <TextBlock Text="{Binding Path=RowData.Row.Category, Mode=OneWay}" />

                                    </ToolTip>

                                    </ToolTipService.ToolTip>

                                    </dxe:TextEdit>

                                    </DataTemplate>

                                    </dxg:GridColumn.CellTemplate>

                                    </dxg:GridColumn>



                                    However, though the column shows Name, we keep getting the error: 'ToolTip' cannot have a logical or visual parent. Any suggestion. Note that we use DevExpress.Wpf.Grid.v9.3 (version 9.3.7.0) in Visual Studio 2008. Thanks.



                                    Andy


                                1 Solution

                                Creation Date Rating Importance Sort by
                                0

                                Hello Andy,

                                Thank you for providing the sample code.

                                There is no need to put a TextBlock element in the ToolTipService.ToolTip. You can bind the ToolTip directly to the Category value. Here is some sample code:

                                [XAML]
                                <dxe:TextEdit Name="PART_Editor"> <ToolTipService.ToolTip> <Binding Path="Data.Category"/> </ToolTipService.ToolTip> </dxe:TextEdit>

                                I am attaching a small sample project, illustrating this approach. Please try it on your side and let us know how it goes.

                                • Louis-Martin Cote 01.04.2013

                                  Is there a way to have more than one information, for example Data.Name, Data.Address, etc... in the binding path?

                                • Hi,

                                  I need additional time to research why you get an issue if you use the tooltip like in your first message. As a workaround, you can execute the following code:

                                  [XAML]
                                  <dxg:GridColumn FieldName="Name"> <dxg:GridColumn.CellTemplate> <DataTemplate> <ContentControl> <ContentControl.ToolTip> <StackPanel> <TextBlock Text="{Binding Path=Data.Category, Mode=OneWay}"/> <TextBlock Text="{Binding Path=Data.Name, Mode=OneWay}"/> </StackPanel> </ContentControl.ToolTip> <dxe:TextEdit Name="PART_Editor"> </dxe:TextEdit> </ContentControl> </DataTemplate> </dxg:GridColumn.CellTemplate> </dxg:GridColumn>
                                  Please do not hesitate to contact us if you need further assistance.

                                  Thanks

                                • Hi,

                                  We have researched the issue and found that it was a bug in version 9.3. We fixed it in version 11.1. If you wish to use 9.3.7, use my workaround; alternatively, you can update our controls to the latest version.
                                  Please do not hesitate to contact us if you need further assistance.

                                  Thanks

                                If you need additional product information, write to us at info@devexpress.com or call us at +1 (818) 844-3383

                                FOLLOW US

                                DevExpress engineers feature-complete Presentation Controls, IDE Productivity Tools, Business Application Frameworks, and Reporting Systems for Visual Studio, along with high-performance HTML JS Mobile Frameworks for developers targeting iOS, Android and Windows Phone. Whether using WPF, ASP.NET, WinForms, HTML5 or Windows 10, DevExpress tools help you build and deliver your best in the shortest time possible.

                                Copyright © 1998-2017 Developer Express Inc.
                                All trademarks or registered trademarks are property of their respective owners