This documentation is archived and is not being maintained.

LiteralText Class

Provides the run-time instantiation of literal text specified in a form.

Namespace:  System.Web.UI.MobileControls
Assembly:  System.Web.Mobile (in System.Web.Mobile.dll)

public class LiteralText extends PagedControl
<mobile:LiteralText />

The only place where external code must access the members of a LiteralText class is in adapters written for a new class of devices. Be sure that an adapter is written for literal text.

The style with which literal text is rendered will differ based on device, but the literal text will appear on all devices. Between HTML and WML, there are no differences.

The text will render in the following manner:

  • The control renders literal text on its own line with the appropriate style attributes applied.

  • When nesting tags, the hyperlink tag (anchor tag: <a>) does not recognize nested tags. For example, nesting the <b> or <i> tag as literal text inside the <a> tag will not render a link as bold or italic. The control completely ignores all tags inside of the <a> tag.


It is important for an adapter to use the TextView.Text property to dynamically set the text that you want to display on a form. Do not use this class to do so.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0, 2.0, 1.1