TextView | .NET 1.1, disposable |
System.Web.UI.MobileControls (system.web.mobile.dll) | class |
The TextView control is similar to the
Label in that it provides a control that displays
text which you can programmatically modify through the
Text property. However, the
TextView also has the ability to subdivide its
content over multiple pages automatically. If the
TextView is on a Panel or
Form which has its Paginate
property set to True, the text it contains will
automatically be divided into distinct
TextViewElement objects, one for each page. You
can access individual TextViewElement instances
using the GetElement( ) method (and supplying an
index number), and you can use properties like
FirstVisibleElementIndex and
LastVisibleElementIndex to examine the pagination
that has been applied automatically.
You can use insert markup tags directly into the text of a
TextView. Supported tags include
<a> (anchor), <b>
(bold), <i> (italic),
<br> (line break), and
<p> (paragraph). These tags will be rendered
in a device-independent manner, which means that a
<p> could conceivably be translated into a
<br> tag if required by the client device.
In order to ensure compatibility across a broad range of devices, all
other tags are ignored, and will never affect the
control's output.
public class TextView : PagedControl {
// Public Constructors
public TextView( );
// Public Instance Properties
public int FirstVisibleElementIndex{get; }
public int FirstVisibleElementOffset{get; }
public int ItemCount{set; get; } // overrides PagedControl
public int ItemsPerPage{set; get; } // overrides PagedControl
public int LastVisibleElementIndex{get; }
public int LastVisibleElementOffset{get; }
public string Text{set; get; }
// Protected Instance Properties
protected override int InternalItemCount{get; } // overrides PagedControl
protected override int ItemWeight{get; } // overrides PagedControl
// Public Instance Methods
public TextViewElement GetElement(int index);
public override void PaginateRecursive(ControlPager pager); // overrides PagedControl
// Protected Instance Methods
protected override void OnRender(System.Web.UI.HtmlTextWriter writer); // overrides MobileControl
// Events
public event LoadItemsEventHandler LoadItems; // overrides PagedControl
}
Hierarchy
System.Object
System.Web.UI.Control(System.ComponentModel.IComponent,
System.IDisposable,
System.Web.UI.IParserAccessor,
System.Web.UI.IDataBindingsAccessor)
MobileControl(System.Web.UI.IAttributeAccessor)
PagedControl
TextView
Returned By
System.Web.UI.MobileControls.Adapters.HtmlTextViewAdapter.Control,
System.Web.UI.MobileControls.Adapters.WmlTextViewAdapter.Control