Add bookmarks for text in RichTextBox

Source: Internet
Author: User

1. The main functions of this article are as follows:

1. Add bookmarks

2. Delete bookmarks

3. Locate bookmarks

2. Application Software: vs2010

3. Implementation Process

3.1 first create a WPF project, named addlabel

3.2 Based on the content in the function layout window, two windows are used:

The main window is used to store the RichTextBox Control.

Controls for bookmarking in subwindow Storage

The layout picture is as follows:

3.3 implement the functions of each control based on the layout.

3.3.1 add bookmarks: add the names of the bookmarks to ListBox and add the names and bookmarksArticleSave

In the position.txt file, you can view the previously added bookmarks when you open the bookmarks.

3.3.2 Delete bookmarks: delete the name of the bookmarks in ListBox and delete the names and locations of the bookmarks in position.txt.

3.3.3 bookmarks positioning: Click the location where the bookmarks are saved in the article.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.