This project has moved. For the latest updates, please go here.

CheckComboBox tooltip

Mar 11, 2014 at 4:15 PM
I would like to display a tooltip for each element in the combobox.
I have tried to set a itemtemplate in order to override the default item template in order to be able to set this tooltip but it seems that this itemtemplate is ignored.
Developer
Mar 11, 2014 at 6:13 PM
Hi,

The following code works. I redefined the ItemTemplate for the CheckComboBox. When the mouse goes over an item of the CheckComboBox, its tooltip is displayed.
 <Window.Resources>
      <x:Array x:Key="ComboBoxSource"
               Type="sys:String">
         <sys:String>First</sys:String>
         <sys:String>Second</sys:String>
         <sys:String>Third</sys:String>
      </x:Array>
   </Window.Resources>
    <Grid>
      <xctk:CheckComboBox x:Name="_checkComboBox"
                          ItemsSource="{StaticResource ComboBoxSource}"
                          Height="22">
         <xctk:CheckComboBox.ItemTemplate>
            <DataTemplate>
               <StackPanel Orientation="Horizontal"
                           ToolTip="{Binding}">
                  <TextBlock Text="My Text is: " />
                  <TextBlock Text="{Binding}" />
               </StackPanel>
            </DataTemplate>
         </xctk:CheckComboBox.ItemTemplate>
      </xctk:CheckComboBox>
   </Grid>
Marked as answer by Tekarihoken on 3/12/2014 at 6:58 AM
Mar 12, 2014 at 1:46 PM
Edited Mar 12, 2014 at 2:03 PM
Ho sorry I was using version 2.0 (with personnal patch concerning zoombox). And i have read the change log of the version 2.2 (plus) instead of the version 2.1 log that's why i haven't seen that the checkcombobox was modified with version 2.1.