# Using the Built-in UI to work with Tables

* [Creating a Table](https://www.telerik.com/products/wpf/documentation/controls/radrichtextbox/document-elements/table/table-ui#creating-a-table)

* [Formatting a Table](https://www.telerik.com/products/wpf/documentation/controls/radrichtextbox/document-elements/table/table-ui#formatting-a-table)

## Creating a Table

You can enable the user to create a table via the built-in UI of the **RadRichTextBox**. This is done by using the **RadRichTextBoxRibbonUI**, which exposes two different ways of creating a table by selection in the UI or on button click. To learn more about how to use the **RadRichTextBoxRibbonUI** read [this topic](https://www.telerik.com/products/wpf/documentation/controls/radrichtextbox/ui-for-applying-rich-text-formatting/features-radrichtextboxribbonui).

![Rad Rich Text Box Features Layout Elements Tables 02](https://www.telerik.com/products/wpf/documentation/assets/461a3f7c09137f36326f5e037de99299/radrichtextbox_features_layoutelements_tables_02.png)

You can also use the **InsertTableDialog**, which comes out of the box. To show it upon a user action just call the **ShowInsertTableDialog()** method of the **RadRichTextBox**. Here is a snapshot of it.

> The **RadRichTextBoxUI** also uses this dialog.

![Rad Rich Text Box Features Layout Elements Tables 04](https://www.telerik.com/products/wpf/documentation/assets/801e2b3e3a196a3a5cf71b83a324cdd4/radrichtextbox_features_layoutelements_tables_04.png)

A table could be deleted or modified via the Table Tools’ contextual tab **Layout**. There are UI buttons for each of the API methods used for deleting and modifying a table.

![Rad Rich Text Box Features Layout Elements Tables 03](https://www.telerik.com/products/wpf/documentation/assets/a13239bf764b74d55b9b1724ec676076/radrichtextbox_features_layoutelements_tables_03.png)

### Formatting a Table

You can enable the user to modify a table via the built-in UI of the **RadRichTextBox**. This is done by using the **RadRichTextBoxRibbonUI**, which exposes a **Table Tools** contextual menu with two tabs – **Design** and **Layout**. They expose UI buttons for all API methods used for formatting and modifying a table. To learn more about how to use the **RadRichTextBoxRibbonUI** read [this topic](https://www.telerik.com/products/wpf/documentation/controls/radrichtextbox/ui-for-applying-rich-text-formatting/features-radrichtextboxribbonui).

![Rad Rich Text Box Features Layout Elements Tables 05](https://www.telerik.com/products/wpf/documentation/assets/9b43727d001ba820e349b573594857d7/radrichtextbox_features_layoutelements_tables_05.png)

The **Design** contextual tab allows you to use a predefined set of formatting options called Table styles. The **TableStylesGallery** offers a way to easily create, delete, modify and apply table styles in a document. To learn more about how to use the TableStylesGallery read [this topic](https://www.telerik.com/products/wpf/documentation/controls/radrichtextbox/ui-for-applying-rich-text-formatting/ui-for-applying-formatting-table-styles-gallery).

![Rad Rich Text Box Features Layout Elements Tables 07](https://www.telerik.com/products/wpf/documentation/assets/9e1a5fe43c790d2560fdddd96339a6c9/radrichtextbox_features_layoutelements_tables_07.png)

Additionally, the built-in context menu of the **RadRichTextBox** gives the user the possibility to open the **Table Properties** and **Table Borders** dialogs.

![Rad Rich Text Box Features Layout Elements Tables 06](https://www.telerik.com/products/wpf/documentation/assets/6acc887a1b38eb8537371462d29805ba/radrichtextbox_features_layoutelements_tables_06.png)

> tip To wire these dialogs to your own UI you can use the **ShowTablePropertiesDialog()** method of **RadRichTextBox** or the **ShowTablePropertiesCommand**.
