Share via


BooleanOption Enumeration

Specifies a style option. This class cannot be inherited.

public sealed enum System.Web.UI.MobileControls.BooleanOption : 
   System.Enum

Remarks

The BooleanOption enumeration represents the state of a style. In ASP.NET, the Font-Bold or Font-Italic attributes take a BooleanOption enumeration. A typical usage is shown in the following ASP.NET code fragment.

<mobile:Page
   runat="server"
   Font-Bold="True">
      <mobile:Form
         runat="server"
         Font-Italic="True">
      </mobile:Form>
</mobile:Page>

All text inside the form will display as bold and italic, because the form inherits the bold style from its mobile page container.

Members

Member name Description
NotSet Default value. If the value is NotSet, then the font attributes are inherited from the control's style, or, if the style is not defined, from the control's parent control.
False The specified style will not be applied.
True The specified style will be applied.

Example

The following code example changes the font style of a form to italic.

[C#]

private void Form1_Activate(object sender, System.EventArgs e)
{
   Form1.Font.Italic = BooleanOption.True;
}

Requirements

Namespace: System.Web.UI.MobileControls

Assembly: System.Web.Mobile

See Also

System.Web.UI.MobileControls Namespace