[Expand]General Information
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Collapse]WPF Controls
  Prerequisites
 [Expand]What's Installed
 [Expand].NET Core 3 Support
 [Expand]Common Concepts
 [Expand]MVVM Framework
 [Collapse]Controls and Libraries
   Reporting
  [Expand]Data Grid
  [Expand]Ribbon, Bars and Menu
  [Expand]Charts Suite
  [Expand]Pivot Grid
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Collapse]Rich Text Editor
   [Expand]Product Information
    Product Class Structure
    Supported Formats
   [Expand]Getting Started
   [Collapse]RichEditControl Document
    [Expand]Document Structure
    [Collapse]Document Elements
      Positions and Ranges
      Paragraphs
      Inline Pictures
      Hyperlinks and Bookmarks
      Headers and Footers
      Tables
      Range Permissions
      Sections
      Lists
      Shapes
      Text Boxes
      Comments
      Checkboxes
      Document Properties
     Measure Units
   [Expand]Fields
    Text Formatting
    Import and Export
   [Expand]Page Layout
    Printing
    AutoCorrect
    Mail Merge
    Restrictions and Protection
   [Expand]Visual Elements
    Services
    Events
    Commands
    HTML Tag Support
   [Expand]Examples
  [Expand]Tree List
  [Expand]Gauge Controls
  [Expand]Map Control
  [Expand]Layout Management
  [Expand]Windows Modern UI
  [Expand]Printing-Exporting
  [Expand]Data Editors
  [Expand]Navigation Controls
  [Expand]Spell Checker
  [Expand]Property Grid
  [Expand]PDF Viewer
  [Expand]TreeMap Control
  [Expand]Gantt Control
  [Expand]Diagram Control
  [Expand]Windows and Utility Controls
   Dialogs, Notifications and Panels
  [Expand]Scheduler (legacy)
 [Expand]Scaffolding Wizard
 [Expand]Localization
  Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Expand]Report and Dashboard Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]eXpress Persistent Objects
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
View this topic on docs.devexpress.com (Learn more)

Checkboxes

The RichEditControl allows you to view and export a document containing checkbox form fields. These form fields are interactive, so end-users can toggle their state as needed. The resulting document can be exported to PDF or HTML format.

Important

Currently, RichEditControl supports only checkbox form fields. ActiveX and form control checkboxes are not supported.

RichEditControl does not support using checkboxes in OpenDocument Text (.odt) and HTML documents.

Expanded Checkboxes in API

Use members from the table below to manage checkboxes in code. Refer to the How to: Create a Checkbox topic for more details.

API

Description

FormFieldCollection.InsertCheckBox

Inserts a checkbox form field to a given document position and adds the created CheckBox object to the FormFieldCollection. Note that you can only insert checkboxes in the main document body. An FormFieldIncorrectSubDocumentException occurs on attempt to insert the checkbox into a comment, header, footer or text box.

FormField.Name

Specifies a bookmark name associated with the checkbox.

CheckBox.State

Gets or sets the checkbox's state.

CheckBox.SizeMode

Defines the checkbox's size mode. Use the CheckBox.Size property to specify the exact size.

FormField.HelpTextType

FormField.StatusTextType

Specifies the type of instructional text that accompanies the checkbox.

FormField.HelpText

FormField.StatusText

Gets or sets the checkbox's instructional text. With the ...TextType property set to FormFieldTextType.Auto, make sure that the ...Text property value is equal to one of the document's AutoText gallery entries.

Note

A complete sample project is available at https://github.com/DevExpress-Examples/wpf-richedit-document-api-t213968.

Expanded Checkboxes in the User Interface

End-users can change the checkbox's state by double-clicking the object. The state defined by an end-user is passed to the CheckBox.DefaultState property.

Note

RichEditControl has the following limitations when working with checkboxes in the UI:

  • It does not provide user interface elements to manage checkboxes.
  • It cannot display instructional text provided for the checkbox.
  • It does not support macros assigned with the checkbox.

Is this topic helpful?​​​​​​​