How to display tooltip for a disabled Listbox items.

3 posts, 0 answers
  1. Chocks
    Chocks avatar
    12 posts
    Member since:
    May 2012

    Posted 18 Dec 2012 Link to this post


    I am having a listbox, which will disable and enable at runtime, I need to get the tooltip to be displayed for the listbox items, even when it is disabled. Currently tooltip is working only when the listbox is enabled. 

     ListBox x:Name="lstEpisod" ItemsSource="{Binding ScopeDetails,Mode=TwoWay}" Height="115" Width="212" ScrollViewer.HorizontalScrollBarVisibility="Hidden" Background="#FFF3F3F3" ItemTemplate="{StaticResource EpisodeEncounterTemplate}" Margin="0,5,0,2" TabIndex="0" HorizontalAlignment="Left"> 
    <Style TargetType="ListBoxItem"> 
     <Setter Property="Padding" Value="0" /> 
     <Setter Property="Margin" Value="0"/> 
     <Setter Property="BorderThickness" Value="0"/> 
     <Setter Property="Background" Value="#FFF3F3F3"/> 
     <Setter Property="Foreground" Value="Black"/> 
    <!--<Setter Property="ToolTipService.ToolTip" Value="{Binding Text, RelativeSource={RelativeSource Self}}"/>--> 

    Thanks for any support.

  2. Kevin
    Kevin avatar
    6 posts
    Member since:
    Oct 2014

    Posted 15 Jul 2015 Link to this post

    i am interesting if you ever found a solution to this. I have the same issue with WPF
  3. Nasko
    Nasko avatar
    727 posts

    Posted 16 Jul 2015 Link to this post

    Hello Kevin,

    In order to visualize the ToolTip when the items are disabled you need to set the ShowOnDisabled property of the ToolTipService class to "True". Please, check the attached sample project that demonstrates that approach and let us know if it worked for you. 

    Please, notice the proposed approach only works for WPF.

    Hopes this helps.

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top