This documentation is archived and is not being maintained.

ObjectList::CommandStyle Property

Gets or sets the style used for the object list commands. This API is obsolete. For information about how to develop ASP.NET mobile applications, see the www.asp.net/mobile Web site.

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

public:
property Style^ CommandStyle {
	Style^ get ();
	void set (Style^ value);
}
<asp:ObjectList CommandStyle="Style" />

Property Value

Type: System.Web.UI.MobileControls::Style
The style used for the object list commands.

If this property is programmatically set, it is not persisted unless the property is set dynamically on each request. If the property is set declaratively, the property is set on each request. There is no default.

Since different devices have different requirements for styles. You may want several DeviceSpecific settings for the CommandStyle property.

The following code example demonstrates how to the use the CommandStyle property to set the style of an ObjectList using a declarative DeviceSpecific section to specify different CommandStyle settings for different devices.

NoteNote

The following code sample uses the single-file code model and may not work correctly if copied directly into a code-behind file. This code sample must be copied into an empty text file that has an .aspx extension. For more information, see ASP.NET Web Page Code Model.

No code example is currently available or this language may not be supported.

This is a sample Web.config file with several device specific filters.


<configuration>
  <system.web>
    <compilation debug="true" />
    <authentication mode="Windows" />
    <customErrors mode="Off" />
    <httpRuntime useFullyQualifiedRedirectUrl="true" />
    <mobileControls cookielessDataDictionaryType="System.Web.Mobile.CookielessData" />

    <deviceFilters>
      <!-- Only a few filters are provided here -->
      <filter name="isJPhone" compare="Type" argument="J-Phone" />
      <filter name="isHTML32" compare="PreferredRenderingType" argument="html32" />
      <filter name="isWML11" compare="PreferredRenderingType" argument="wml11" />
    </deviceFilters>

  </system.web>
</configuration>


.NET Framework

Supported in: 4, 3.5, 3.0, 2.0, 1.1

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Show: