Log In
Home
Support
Demos
Documentation
Blogs
Training
Webinars
[Expand]General Information
[Collapse]WinForms Controls
  Prerequisites
 [Expand]What's Installed
 [Expand]Build an Application
 [Collapse]Controls and Libraries
  [Expand]Forms and User Controls
  [Expand]Messages, Notifications and Dialogs
  [Expand]Editors and Simple Controls
  [Expand]Ribbon, Bars and Menu
  [Expand]Application UI Manager
  [Expand]Docking Library
  [Expand]Data Grid
  [Expand]Vertical Grid
  [Expand]Pivot Grid
  [Expand]Tree List
  [Expand]Chart Control
  [Expand]Diagrams
  [Expand]Gauges
  [Expand]Map Control
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Collapse]Rich Text Editor
    Overview
   [Expand]Getting Started
   [Collapse]Fundamentals
    [Expand]RichEditControl
    [Collapse]Document
      Document Model
      Document Layout
      Positions and Ranges
      Characters
      Paragraphs
      Inline Pictures
      Document Fields
      Hyperlinks and Bookmarks
      Headers and Footers
      Tables
      Range Permissions
      Sections
      Styles
      Numbered and Bulleted Lists
      Floating Objects (Shapes)
      Text Boxes
      Comments
      Document Properties
     Supported Document Formats
    [Expand]Fields
     Commands
     Services
     Layout API
     Product Class Structure
     Default Keyboard Shortcuts
     Measure Units
     HTML Tag Interpretation
   [Expand]Concepts
   [Expand]Visual Elements
   [Expand]Examples
   [Expand]Member Tables
  [Expand]Spell Checker
  [Expand]Form Layout Managers
  [Expand]Navigation Controls
  [Expand]Printing-Exporting
  [Expand]PDF Viewer
   Reporting
  [Expand]Snap
  [Expand]TreeMap Control
 [Expand]Common Features
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Document Server
[Expand]Reporting
[Expand]Report Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

Paragraphs

Expanded Overview

A Section consists of paragraphs. The Paragraph class represents the paragraph entity in the document model. You can access the collection of paragraphs in a document using the SubDocument.Paragraphs property. The Section.Paragraphs property gives you a collection of paragraphs in a particular section of a document.

To insert a paragraph at an arbitrary position, use the ParagraphCollection.Insert method accessible by Document.Paragraphs.Insert notation.

For the specified DocumentPosition, use the ReadOnlyParagraphCollection.Get method (Document.Paragraphs.Get(DocumentRange range) notation) to get the encompassing Paragraph.

Expanded Formatting

Paragraph formatting can be modified using the ParagraphProperties object accessible via the SubDocument.BeginUpdateParagraphs method. See also the Text Formatting topic.

Show Me

A complete sample project is available in the DevExpress Code Examples database at http://www.devexpress.com/example=E5219.

Expanded Paragraph Text

To modify text of the paragraph, get its Paragraph.Range or any position(s) within that range and use SubDocument methods (for example, SubDocument.InsertRtfText, SubDocument.AppendText etc.) for the obtained DocumentRange object.

How would you rate this topic?​​​​​​​