ComponentOne TabControl for ASP.NET AJAX: TabControl for ASP.NET AJAX Task-Based Help > Adding and Manipulating Page Content > Adding Text to a C1TabControl Tab Page

Adding Text to a C1TabControl Tab Page

In this topic, you will learn how to add text to a C1TabControl control using the designer and XHTML markup.

In Design View

To add text to a tab page, simply place your cursor inside the tab page and type (or copy) text onto the tab page.

 

 

Once you've added text to the tab page, you can use Visual Studio's Formatting toolbar (to view this toolbar, use the following path: View | Toolbars | Formatting) to format the text. The image below shows a C1TabPage with formatted text:

 

In Source View

You can add text to a C1TabPage in Source view by placing text between the <cc1:C1TabPage> tags. To format the text, you will use XHTML markup.

To add text to a C1TabPage in Source view, follow these steps:

1.   Add a C1TabControl control to your project.

2.   Click C1TabControl's smart tag () to open the C1TabControl Tasks menu and select TabControl Designer.

The C1TabControl Designer Form appears.

3.   Use the Add Child Item button  to add one tab page to the C1TabControl.

4.   Switch to Source view and paste the following text and XHTML tags between the <cc1: C1TabPage> tags:

 

You can also add text to a <b>C1TabControl</b> control in Source view. Simply place the text between the <span style="color: #0000ff; font-family: Courier New">&lt;cc1: C1TabPage&gt;</span> tags and use HTML markup to format the text.

 

5.   Click the Design tab to return to Design view and observe that text has been added to the C1TabPage of the C1TabControl control. Your result will resemble the following image:


Send comments about this topic to ComponentOne.
Copyright © 1987-2010 ComponentOne LLC. All rights reserved.