2

Is there a way to dynamically highlight portions of text in a TextBlock? Note that I do not know in advance which parts will need to be highlighted.

Tilvia
  • 261
  • 1
  • 4
  • 14
  • Similar question answered here: http://stackoverflow.com/questions/751741/wpf-textblock-highlight-certain-parts-based-on-search-condition – Indy9000 Nov 23 '11 at 11:27
  • 1
    I also posted a HighlightTextBlock as part of an answer for a different question [here](http://stackoverflow.com/questions/7854570/how-to-implement-a-search-that-causes-multi-column-record-filtering-in-xamdatagr/7956628#7956628) – AndrewS Nov 23 '11 at 14:42
  • AndrewS, just what I was looking for :) – Tilvia Nov 23 '11 at 16:12
  • Possible duplicate of [How to display search results in a WPF items control with highlighted query terms](https://stackoverflow.com/questions/3728584/how-to-display-search-results-in-a-wpf-items-control-with-highlighted-query-term) – Rekshino Feb 21 '18 at 08:22

0 Answers0