This documentation is archived and is not being maintained.

XhtmlTextWriter.SetDocType Method

Specifies the XHTML document type for the text writer to render to the page or control.

Namespace: System.Web.UI
Assembly: System.Web (in system.web.dll)

public virtual void SetDocType (
	XhtmlMobileDocType docType
public void SetDocType (
	XhtmlMobileDocType docType
public function SetDocType (
	docType : XhtmlMobileDocType
Not applicable.



One of the XhtmlMobileDocType enumeration values.

Use the SetDocType method in a custom page adapter to define the type of XHTML that you want to render to the requesting device. Supported document types are defined in the XhtmlMobileDocType enumeration.

Windows 98, Windows Server 2000 SP4, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0