Search code examples
c#.netwinformsprogrammers-notepad

How to perform Find/FindNext operation in Notepad C# winforms


Please anyone suggest me some ideas regarding how to perform find/findNext operation in notepad program in C#. I want to search for all occurrence of strings in RichTextBox and highlight each occurrence on click of findNext button.


Solution

  • you may take a look at this code : http://www.dreamincode.net/code/snippet2466.htm and for hightlighting Highlight text in TextBox/Label/RichTextBox using C#