次の方法で共有


Xml クラス

定義

書式設定や拡張スタイルシート言語変換 (XSLT) を使用せずに XML ドキュメントを表示します。

public ref class Xml : System::Web::UI::Control
public class Xml : System.Web.UI.Control
type Xml = class
    inherit Control
Public Class Xml
Inherits Control
継承

次のコード例は、サンプル XML ファイルと XSL 変換スタイル シートから XmlDocument オブジェクトと XslTransform オブジェクトを作成する方法を示しています。 その後、オブジェクトは XML コントロールによって XML ドキュメントを表示するために使用されます。

<!-- 
The following example demonstrates how to create XmlDocument and 
XslTransform objects from the sample XML and XSL Transform files. 
The objects are then used by the Xml control to display the XML 
document. Make sure the sample XML file is called People.xml and 
the sample XSL Transform file is called Peopletable.xsl.
-->

<%@ Page Language="C#" AutoEventWireup="True" %>
<%@ Import Namespace="System.Xml" %>
<%@ Import Namespace="System.Xml.Xsl" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
   <script runat="server">
      void Page_Load(Object sender, EventArgs e) 
      {
//<Snippet3>
         XmlDocument doc = new XmlDocument();
         doc.Load(Server.MapPath("people.xml"));
//</Snippet3>

//<Snippet4>
         XslTransform trans = new XslTransform();
         trans.Load(Server.MapPath("peopletable.xsl"));
//</Snippet4>

         xml1.Document = doc;
         xml1.Transform = trans;
      }
   </script>
<head runat="server">
    <title>Xml Class Example</title>
</head>
<body>
   <h3>Xml Example</h3>
      <form id="form1" runat="server">
         <asp:Xml id="xml1" runat="server" />
      </form>
</body>
</html>


<!-- 
For this example to work, paste the following code into a file
named peopletable.xsl. Store the file in the same directory as
your .aspx file.

<?xml version="1.0" encoding="utf-8"?>

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:template match="/People">
    <xsl:apply-templates select="Person" />
  </xsl:template>

  <xsl:template match="Person">
    <table width="100%" border="1">
      <tr>
        <td>
          <b>
            <xsl:value-of select="Name/FirstName" />
             
            <xsl:value-of select="Name/LastName" />
          </b>
        </td>
      </tr>
      <tr>
        <td>
          <xsl:value-of select="Address/Street" /><br />
          <xsl:value-of select="Address/City" />
          ,
          <xsl:value-of select="Address/State" />
          <xsl:value-of select="Address/Zip" />
        </td>
      </tr>
      <tr>
        <td>
          Job Title: <xsl:value-of select="Job/Title" /><br />
          Description: <xsl:value-of select="Job/Description" />
        </td>
      </tr>
    </table>
  </xsl:template>

  <xsl:template match="bookstore">

      <bookstore>
         <xsl:apply-templates select="book"/>
      </bookstore>
   </xsl:template>

   <xsl:template match="book">
      <book>
         <xsl:attribute name="ISBN">
            <xsl:value-of select="@ISBN"/>
         </xsl:attribute>
         <price>
            <xsl:value-of select="price"/>
         </price>
         <xsl:text>
         </xsl:text>
      </book>
   </xsl:template>

</xsl:stylesheet>

-->

<!--
For this example to work, paste the following code into a file 
named people.xml. Store the file in the same directory as 
your .aspx file.

<?xml version="1.0" encoding="utf-8" ?>
<People>
  <Person>
    <Name>
      <FirstName>Joe</FirstName>
      <LastName>Suits</LastName>
    </Name>
    <Address>
      <Street>1800 Success Way</Street>
      <City>Redmond</City>
      <State>WA</State>
      <ZipCode>98052</ZipCode>
    </Address>
    <Job>
      <Title>CEO</Title>
      <Description>Wears the nice suit</Description>
    </Job>
  </Person>

  <Person>
    <Name>
      <FirstName>Linda</FirstName>
      <LastName>Sue</LastName>
    </Name>
    <Address>
      <Street>1302 American St.</Street>
      <City>Paso Robles</City>
      <State>CA</State>
      <ZipCode>93447</ZipCode>
    </Address>
    <Job>
      <Title>Attorney</Title>
      <Description>Stands up for justice</Description>
    </Job>
  </Person>

  <Person>
    <Name>
      <FirstName>Jeremy</FirstName>
      <LastName>Boards</LastName>
    </Name>
    <Address>
      <Street>34 Palm Avenue</Street>
      <City>Waikiki</City>
      <State>HI</State>
      <ZipCode>98052</ZipCode>
    </Address>
    <Job>
      <Title>Pro Surfer</Title>
      <Description>Rides the big waves</Description>
    </Job>
  </Person>

  <Person>
    <Name>
      <FirstName>Joan</FirstName>
      <LastName>Page</LastName>
    </Name>
    <Address>
      <Street>700 Webmaster Road</Street>
      <City>Redmond</City>
      <State>WA</State>
      <ZipCode>98073</ZipCode>
    </Address>
    <Job>
      <Title>Web Site Developer</Title>
      <Description>Writes the pretty pages</Description>
    </Job>
  </Person>
</People>

-->
<!-- 
The following example demonstrates how to create XmlDocument and 
XslTransform objects from the sample XML and XSL Transform files. 
The objects are then used by the Xml control to display the XML 
document. Make sure the sample XML file is called People.xml and 
the sample XSL Transform file is called Peopletable.xsl.
-->

<%@ Page Language="VB" AutoEventWireup="True" %>
<%@ Import Namespace="System.Xml" %>
<%@ Import Namespace="System.Xml.Xsl" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
   <script runat="server">
      Sub Page_Load(sender As Object, e As EventArgs)
'<Snippet3>
         Dim doc As XmlDocument = New XmlDocument()
         doc.Load(Server.MapPath("people.xml"))
'</Snippet3>

'<Snippet4>
         Dim trans As XslTransform = new XslTransform()
         trans.Load(Server.MapPath("peopletable.xsl"))
'</Snippet4>

         xml1.Document = doc
         xml1.Transform = trans
      End Sub
</script>
<head runat="server">
    <title>Xml Class Example</title>
</head>
<body>
   <h3>Xml Example</h3>
   <form id="form1" runat="server">
      <asp:Xml id="xml1" runat="server" />
   </form>
</body>
</html>

<!-- 
For this example to work, paste the following code into a file
named peopletable.xsl. Store the file in the same directory as
your .aspx file.

<?xml version="1.0" encoding="utf-8"?>

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:template match="/People">
    <xsl:apply-templates select="Person" />
  </xsl:template>

  <xsl:template match="Person">
    <table width="100%" border="1">
      <tr>
        <td>
          <b>
            <xsl:value-of select="Name/FirstName" />
             
            <xsl:value-of select="Name/LastName" />
          </b>
        </td>
      </tr>
      <tr>
        <td>
          <xsl:value-of select="Address/Street" /><br />
          <xsl:value-of select="Address/City" />
          ,
          <xsl:value-of select="Address/State" />
          <xsl:value-of select="Address/Zip" />
        </td>
      </tr>
      <tr>
        <td>
          Job Title: <xsl:value-of select="Job/Title" /><br />
          Description: <xsl:value-of select="Job/Description" />
        </td>
      </tr>
    </table>
  </xsl:template>

  <xsl:template match="bookstore">

      <bookstore>
         <xsl:apply-templates select="book"/>
      </bookstore>
   </xsl:template>

   <xsl:template match="book">
      <book>
         <xsl:attribute name="ISBN">
            <xsl:value-of select="@ISBN"/>
         </xsl:attribute>
         <price>
            <xsl:value-of select="price"/>
         </price>
         <xsl:text>
         </xsl:text>
      </book>
   </xsl:template>

</xsl:stylesheet>

-->

<!--
For this example to work, paste the following code into a file 
named people.xml. Store the file in the same directory as 
your .aspx file.

<?xml version="1.0" encoding="utf-8" ?>
<People>
  <Person>
    <Name>
      <FirstName>Joe</FirstName>
      <LastName>Suits</LastName>
    </Name>
    <Address>
      <Street>1800 Success Way</Street>
      <City>Redmond</City>
      <State>WA</State>
      <ZipCode>98052</ZipCode>
    </Address>
    <Job>
      <Title>CEO</Title>
      <Description>Wears the nice suit</Description>
    </Job>
  </Person>

  <Person>
    <Name>
      <FirstName>Linda</FirstName>
      <LastName>Sue</LastName>
    </Name>
    <Address>
      <Street>1302 American St.</Street>
      <City>Paso Robles</City>
      <State>CA</State>
      <ZipCode>93447</ZipCode>
    </Address>
    <Job>
      <Title>Attorney</Title>
      <Description>Stands up for justice</Description>
    </Job>
  </Person>

  <Person>
    <Name>
      <FirstName>Jeremy</FirstName>
      <LastName>Boards</LastName>
    </Name>
    <Address>
      <Street>34 Palm Avenue</Street>
      <City>Waikiki</City>
      <State>HI</State>
      <ZipCode>98052</ZipCode>
    </Address>
    <Job>
      <Title>Pro Surfer</Title>
      <Description>Rides the big waves</Description>
    </Job>
  </Person>

  <Person>
    <Name>
      <FirstName>Joan</FirstName>
      <LastName>Page</LastName>
    </Name>
    <Address>
      <Street>700 Webmaster Road</Street>
      <City>Redmond</City>
      <State>WA</State>
      <ZipCode>98073</ZipCode>
    </Address>
    <Job>
      <Title>Web Site Developer</Title>
      <Description>Writes the pretty pages</Description>
    </Job>
  </Person>
</People>

-->

注釈

このトピックの内容は以下のとおりです。

はじめに

Xml コントロールを使用すると、書式設定や XSL 変換を使用せずに XML ドキュメントの内容を表示できます。

XML データの指定

表示する XML ドキュメントは、3 つのプロパティのいずれかを設定して指定します。 これら 3 つのプロパティは、表示できるさまざまな種類の XML ドキュメントを表します。 適切なプロパティを設定することで、 System.Xml.XmlDocument、XML 文字列、または XML ファイルを表示できます。 次の表に、XML ドキュメントを指定するためのプロパティを示します。

財産 説明
Document System.Xml.XmlDocument オブジェクトを使用して XML ドキュメントを設定します。 警告: このプロパティは廃止されています。 このセクションに記載されている他のプロパティのいずれかを使用して、 Xml コントロールの XML コンテンツを設定します。
DocumentContent 文字列を使用して XML ドキュメントを設定します。 メモ:このプロパティは、一般的に、Xml コントロールの開始タグと終了タグの間にテキスト <asp:Xml>を配置することで宣言によって設定されます。
DocumentSource ファイルを使用して XML ドキュメントを設定します。

XML ドキュメントを表示するには、少なくとも 1 つの XML ドキュメント プロパティを設定する必要があります。 複数の XML ドキュメント プロパティが設定されている場合は、最後のプロパティ セットで参照されている XML ドキュメントが表示されます。 他のプロパティのドキュメントは無視されます。

XSL 変換の指定

必要に応じて、2 つのプロパティのいずれかを設定して、XML ドキュメントを出力ストリームに書き込む前に書式設定する XSL 変換 (XSLT) スタイル シートを指定できます。 2 つのプロパティは、XML ドキュメントの書式設定に使用できるさまざまな種類の XSL 変換スタイル シートを表します。 適切なプロパティを設定することで、 System.Xml.Xsl.XslCompiledTransform オブジェクトまたは XSL 変換スタイル シート ファイルを使用して XML ドキュメントの書式を設定できます。 XSL 変換スタイル シートが指定されていない場合、XML ドキュメントは既定の形式で表示されます。 次の表に、XSL 変換スタイル シートを指定するためのプロパティを示します。

財産 説明
Transform 指定した System.Xml.Xsl.XslTransform オブジェクトを使用して XML ドキュメントの書式を設定します。 メモ:System.Xml.Xsl.XslTransform オブジェクトを使用するには、Full Trustアクセス許可が必要です。
TransformSource 指定した XSL 変換スタイル シート ファイルを使用して XML ドキュメントの書式を設定します。

XSL 変換スタイル シートは省略可能です。 Transformまたは TransformSource プロパティを設定する必要はありません。 両方の XSL 変換スタイル シート プロパティが設定されている場合、最後のプロパティ セットによって、XML ドキュメントの書式設定に使用される XSL 変換スタイル シートが決まります。 その他のプロパティは無視されます。

Xml クラスには TransformArgumentList プロパティも用意されており、XSL 変換スタイル シートに省略可能な引数を指定できます。 引数には、XSL 変換 (XSLT) パラメーターまたは拡張オブジェクトのいずれかを指定できます。

宣言構文

<asp:Xml
    DocumentSource="uri"
    EnableTheming="True|False"
    EnableViewState="True|False"
    ID="string"
    OnDataBinding="DataBinding event handler"
    OnDisposed="Disposed event handler"
    OnInit="Init event handler"
    OnLoad="Load event handler"
    OnPreRender="PreRender event handler"
    OnUnload="Unload event handler"
    runat="server"
    SkinID="string"
    TransformSource="string"
    Visible="True|False"
/>

コンストラクター

名前 説明
Xml()

Xml クラスの新しいインスタンスを初期化します。

プロパティ

名前 説明
Adapter

コントロールのブラウザー固有のアダプターを取得します。

(継承元 Control)
AppRelativeTemplateSourceDirectory

このコントロールを含む Page または UserControl オブジェクトのアプリケーション相対仮想ディレクトリを取得または設定します。

(継承元 Control)
BindingContainer

このコントロールのデータ バインディングを含むコントロールを取得します。

(継承元 Control)
ChildControlsCreated

サーバー コントロールの子コントロールが作成されているかどうかを示す値を取得します。

(継承元 Control)
ClientID

ClientID プロパティをオーバーライドし、基本サーバー コントロール識別子を返します。

ClientID

ASP.NET によって生成される HTML マークアップのコントロール ID を取得します。

(継承元 Control)
ClientIDMode

ClientID プロパティの値を生成するために使用するアルゴリズムを取得または設定します。

(継承元 Control)
ClientIDSeparator

ClientID プロパティで使用される区切り文字を表す文字値を取得します。

(継承元 Control)
Context

現在の Web 要求のサーバー コントロールに関連付けられている HttpContext オブジェクトを取得します。

(継承元 Control)
Controls

Controls プロパティをオーバーライドし、基本ControlCollection コレクションを返します。

Controls

UI 階層内の指定したサーバー コントロールの子コントロールを表す ControlCollection オブジェクトを取得します。

(継承元 Control)
DataItemContainer

名前付けコンテナーが IDataItemContainerを実装する場合は、名前付けコンテナーへの参照を取得します。

(継承元 Control)
DataKeysContainer

名前付けコンテナーが IDataKeysControlを実装する場合は、名前付けコンテナーへの参照を取得します。

(継承元 Control)
DesignMode

コントロールがデザイン サーフェイスで使用されているかどうかを示す値を取得します。

(継承元 Control)
Document
古い.

Xml コントロールに表示するXmlDocumentを取得または設定します。

DocumentContent

Xml コントロールに表示する XML ドキュメントを含む文字列を設定します。

DocumentSource

Xml コントロールに表示する XML ドキュメントへのパスを取得または設定します。

EnableTheming

EnableTheming プロパティをオーバーライドします。 このプロパティは、 Xml クラスではサポートされていません。

EnableViewState

サーバー コントロールがそのビューステートを保持するかどうか、およびそれに含まれる子コントロールのビューステートを要求側クライアントに保持するかどうかを示す値を取得または設定します。

(継承元 Control)
Events

コントロールのイベント ハンドラー デリゲートの一覧を取得します。 このプロパティは読み取り専用です。

(継承元 Control)
HasChildViewState

現在のサーバー コントロールの子コントロールに保存されたビューステート設定があるかどうかを示す値を取得します。

(継承元 Control)
ID

サーバー コントロールに割り当てられたプログラム識別子を取得または設定します。

(継承元 Control)
IdSeparator

コントロール識別子を分離するために使用する文字を取得します。

(継承元 Control)
IsChildControlStateCleared

このコントロール内に含まれるコントロールがコントロールの状態を持っているかどうかを示す値を取得します。

(継承元 Control)
IsTrackingViewState

サーバー コントロールがビュー ステートへの変更を保存するかどうかを示す値を取得します。

(継承元 Control)
IsViewStateEnabled

このコントロールに対してビューステートが有効かどうかを示す値を取得します。

(継承元 Control)
LoadViewStateByID

インデックスの代わりに ID して、コントロールがビューステートの読み込みに関与するかどうかを示す値を取得します。

(継承元 Control)
NamingContainer

同じ ID プロパティ値を持つサーバー コントロール間で区別するための一意の名前空間を作成する、サーバー コントロールの名前付けコンテナーへの参照を取得します。

(継承元 Control)
Page

サーバー コントロールを含む Page インスタンスへの参照を取得します。

(継承元 Control)
Parent

ページ コントロール階層内のサーバー コントロールの親コントロールへの参照を取得します。

(継承元 Control)
RenderingCompatibility

レンダリングされた HTML と互換性のある ASP.NET バージョンを指定する値を取得します。

(継承元 Control)
Site

デザイン サーフェイスにレンダリングされるときに、現在のコントロールをホストするコンテナーに関する情報を取得します。

(継承元 Control)
SkinID

SkinID プロパティをオーバーライドします。 このプロパティは、 Xml クラスではサポートされていません。

TemplateControl

このコントロールを含むテンプレートへの参照を取得または設定します。

(継承元 Control)
TemplateSourceDirectory

現在のサーバー コントロールを含む Page または UserControl の仮想ディレクトリを取得します。

(継承元 Control)
Transform

XML ドキュメントを出力ストリームに書き込む前に書式設定する XslTransform オブジェクトを取得または設定します。

TransformArgumentList

スタイル シートに渡され、拡張スタイルシート言語変換 (XSLT) 中に使用される省略可能な引数の一覧を含む XsltArgumentList を取得または設定します。

TransformSource

XML ドキュメントを出力ストリームに書き込む前に書式設定する拡張スタイルシート言語変換 (XSLT) スタイル シートへのパスを取得または設定します。

UniqueID

サーバー コントロールの階層的に修飾された一意の識別子を取得します。

(継承元 Control)
ValidateRequestMode

コントロールがブラウザーからのクライアント入力で潜在的に危険な値をチェックするかどうかを示す値を取得または設定します。

(継承元 Control)
ViewState

同じページに対する複数の要求にわたってサーバー コントロールのビューステートを保存および復元できる状態情報のディクショナリを取得します。

(継承元 Control)
ViewStateIgnoresCase

StateBag オブジェクトで大文字と小文字が区別されないかどうかを示す値を取得します。

(継承元 Control)
ViewStateMode

このコントロールのビューステート モードを取得または設定します。

(継承元 Control)
Visible

サーバー コントロールがページ上の UI としてレンダリングされるかどうかを示す値を取得または設定します。

(継承元 Control)
XPathNavigator

Xml コントロールに関連付けられた XML データを移動および編集するためのカーソル モデルを取得または設定します。

メソッド

名前 説明
AddedControl(Control, Int32)

子コントロールがControl オブジェクトのControls コレクションに追加された後に呼び出されます。

(継承元 Control)
AddParsedSubObject(Object)

XML または HTML のいずれかの要素が解析されたことをサーバー コントロールに通知し、その要素をサーバー コントロールの ControlCollection オブジェクトに追加します。

ApplyStyleSheetSkin(Page)

ページ スタイル シートで定義されているスタイル プロパティをコントロールに適用します。

(継承元 Control)
BeginRenderTracing(TextWriter, Object)

レンダリング データのデザイン時トレースを開始します。

(継承元 Control)
BuildProfileTree(String, Boolean)

サーバー コントロールに関する情報を収集し、ページのトレースが有効になっているときに表示される Trace プロパティに渡します。

(継承元 Control)
ClearCachedClientID()

キャッシュされた ClientID 値を nullに設定します。

(継承元 Control)
ClearChildControlState()

サーバー コントロールの子コントロールのコントロール状態情報を削除します。

(継承元 Control)
ClearChildState()

すべてのサーバー コントロールの子コントロールのビューステート情報とコントロール状態情報を削除します。

(継承元 Control)
ClearChildViewState()

すべてのサーバー コントロールの子コントロールのビューステート情報を削除します。

(継承元 Control)
ClearEffectiveClientIDMode()

現在のコントロール インスタンスと子コントロールの ClientIDMode プロパティを Inheritに設定します。

(継承元 Control)
CreateChildControls()

ASP.NET ページ フレームワークによって呼び出され、コンポジション ベースの実装を使用して、ポスト バックまたはレンダリングの準備として含まれる子コントロールを作成するサーバー コントロールに通知します。

(継承元 Control)
CreateControlCollection()

新しい EmptyControlCollection オブジェクトを作成します。

CreateControlCollection()

サーバー コントロールの子コントロール (リテラルとサーバーの両方) を保持する新しい ControlCollection オブジェクトを作成します。

(継承元 Control)
DataBind()

呼び出されたサーバー コントロールとそのすべての子コントロールにデータ ソースをバインドします。

(継承元 Control)
DataBind(Boolean)

DataBinding イベントを発生させるオプションを使用して、呼び出されたサーバー コントロールとそのすべての子コントロールにデータ ソースをバインドします。

(継承元 Control)
DataBindChildren()

データ ソースをサーバー コントロールの子コントロールにバインドします。

(継承元 Control)
Dispose()

サーバー コントロールがメモリから解放される前に、最終的なクリーンアップを実行できるようにします。

(継承元 Control)
EndRenderTracing(TextWriter, Object)

レンダリング データのデザイン時トレースを終了します。

(継承元 Control)
EnsureChildControls()

サーバー コントロールに子コントロールが含まれているかどうかを判断します。 そうでない場合は、子コントロールが作成されます。

(継承元 Control)
EnsureID()

識別子が割り当てられないコントロールの識別子を作成します。

(継承元 Control)
Equals(Object)

指定したオブジェクトが現在のオブジェクトと等しいかどうかを判断します。

(継承元 Object)
FindControl(String, Int32)

pathOffset パラメーターで指定された、指定したidと整数を持つサーバー コントロールの現在の名前付けコンテナーを検索します。これは、検索に役立ちます。 このバージョンの FindControl メソッドはオーバーライドしないでください。

(継承元 Control)
FindControl(String)

指定したサーバー コントロールのページ名前付けコンテナーを検索します。

FindControl(String)

指定した id パラメーターを使用して、サーバー コントロールの現在の名前付けコンテナーを検索します。

(継承元 Control)
Focus()

Focus() メソッドをオーバーライドします。 このメソッドは、 Xml クラスではサポートされていません。

GetDesignModeState()

コントロールのデザイン時データを取得します。

GetHashCode()

既定のハッシュ関数として機能します。

(継承元 Object)
GetRouteUrl(Object)

ルート パラメーターのセットに対応する URL を取得します。

(継承元 Control)
GetRouteUrl(RouteValueDictionary)

ルート パラメーターのセットに対応する URL を取得します。

(継承元 Control)
GetRouteUrl(String, Object)

ルート パラメーターとルート名のセットに対応する URL を取得します。

(継承元 Control)
GetRouteUrl(String, RouteValueDictionary)

ルート パラメーターとルート名のセットに対応する URL を取得します。

(継承元 Control)
GetType()

現在のインスタンスの Type を取得します。

(継承元 Object)
GetUniqueIDRelativeTo(Control)

指定したコントロールの UniqueID プロパティのプレフィックス部分を返します。

(継承元 Control)
HasControls()

サーバー コントロールに子コントロールが含まれているかどうかを判断します。

HasControls()

サーバー コントロールに子コントロールが含まれているかどうかを判断します。

(継承元 Control)
HasEvents()

コントロールまたは子コントロールのイベントが登録されているかどうかを示す値を返します。

(継承元 Control)
IsLiteralContent()

サーバー コントロールがリテラル コンテンツのみを保持するかどうかを決定します。

(継承元 Control)
LoadControlState(Object)

SaveControlState() メソッドによって保存された前のページ要求から制御状態情報を復元します。

(継承元 Control)
LoadViewState(Object)

SaveViewState() メソッドによって保存された前のページ要求からビューステート情報を復元します。

(継承元 Control)
MapPathSecure(String)

仮想パス (絶対パスまたは相対パス) がマップされる物理パスを取得します。

(継承元 Control)
MemberwiseClone()

現在の Objectの簡易コピーを作成します。

(継承元 Object)
OnBubbleEvent(Object, EventArgs)

サーバー コントロールのイベントがページの UI サーバー コントロール階層に渡されるかどうかを判断します。

(継承元 Control)
OnDataBinding(EventArgs)

DataBinding イベントを発生させます。

(継承元 Control)
OnInit(EventArgs)

Init イベントを発生させます。

(継承元 Control)
OnLoad(EventArgs)

Load イベントを発生させます。

(継承元 Control)
OnPreRender(EventArgs)

PreRender イベントを発生させます。

(継承元 Control)
OnUnload(EventArgs)

Unload イベントを発生させます。

(継承元 Control)
OpenFile(String)

ファイルの読み取りに使用する Stream を取得します。

(継承元 Control)
RaiseBubbleEvent(Object, EventArgs)

イベントのソースとその情報をコントロールの親に割り当てます。

(継承元 Control)
RemovedControl(Control)

Control オブジェクトのControls コレクションから子コントロールが削除された後に呼び出されます。

(継承元 Control)
Render(HtmlTextWriter)

結果を出力ストリームにレンダリングします。

RenderChildren(HtmlTextWriter)

指定した HtmlTextWriter オブジェクトにサーバー コントロールの子のコンテンツを出力します。このオブジェクトは、クライアントにレンダリングされるコンテンツを書き込みます。

(継承元 Control)
RenderControl(HtmlTextWriter, ControlAdapter)

指定されたControlAdapter オブジェクトを使用して、指定されたHtmlTextWriter オブジェクトにサーバー コントロールのコンテンツを出力します。

(継承元 Control)
RenderControl(HtmlTextWriter)

指定された HtmlTextWriter オブジェクトにサーバー コントロールの内容を出力し、トレースが有効になっている場合は、コントロールに関するトレース情報を格納します。

(継承元 Control)
ResolveAdapter()

指定したコントロールのレンダリングを担当するコントロール アダプターを取得します。

(継承元 Control)
ResolveClientUrl(String)

ブラウザーで使用できる URL を取得します。

(継承元 Control)
ResolveUrl(String)

URL を、要求側クライアントで使用できる URL に変換します。

(継承元 Control)
SaveControlState()

ページがサーバーにポストバックされた時刻以降に発生したすべてのサーバー 制御状態の変更を保存します。

(継承元 Control)
SaveViewState()

ページがサーバーにポストバックされてから発生したサーバー コントロールのビューステートの変更を保存します。

(継承元 Control)
SetDesignModeState(IDictionary)

コントロールのデザイン時データを設定します。

(継承元 Control)
SetRenderMethodDelegate(RenderMethod)

サーバー コントロールとそのコンテンツを親コントロールにレンダリングするイベント ハンドラー デリゲートを割り当てます。

(継承元 Control)
SetTraceData(Object, Object, Object)

トレース オブジェクト、トレース データ キー、およびトレース データ値を使用して、レンダリング データのデザイン時トレース用のトレース データを設定します。

(継承元 Control)
SetTraceData(Object, Object)

トレース データ キーとトレース データ値を使用して、レンダリング データのデザイン時トレース用のトレース データを設定します。

(継承元 Control)
ToString()

現在のオブジェクトを表す文字列を返します。

(継承元 Object)
TrackViewState()

ビューステートの変更をサーバー コントロールに追跡して、サーバー コントロールの StateBag オブジェクトに格納できるようにします。 このオブジェクトには、 ViewState プロパティを使用してアクセスできます。

(継承元 Control)

イベント

名前 説明
DataBinding

サーバー コントロールがデータ ソースにバインドされるときに発生します。

(継承元 Control)
Disposed

サーバー コントロールがメモリから解放されたときに発生します。これは、ASP.NET ページが要求されたときに、サーバー コントロールライフサイクルの最後のステージです。

(継承元 Control)
Init

サーバー コントロールが初期化されるときに発生します。これは、そのライフサイクルの最初のステップです。

(継承元 Control)
Load

サーバー コントロールが Page オブジェクトに読み込まれるときに発生します。

(継承元 Control)
PreRender

Control オブジェクトが読み込まれた後、レンダリングの前に発生します。

(継承元 Control)
Unload

サーバー コントロールがメモリからアンロードされるときに発生します。

(継承元 Control)

明示的なインターフェイスの実装

名前 説明
IControlBuilderAccessor.ControlBuilder

このメンバーの説明については、 ControlBuilderを参照してください。

(継承元 Control)
IControlDesignerAccessor.GetDesignModeState()

このメンバーの説明については、 GetDesignModeState()を参照してください。

(継承元 Control)
IControlDesignerAccessor.SetDesignModeState(IDictionary)

このメンバーの説明については、 SetDesignModeState(IDictionary)を参照してください。

(継承元 Control)
IControlDesignerAccessor.SetOwnerControl(Control)

このメンバーの説明については、 SetOwnerControl(Control)を参照してください。

(継承元 Control)
IControlDesignerAccessor.UserData

このメンバーの説明については、 UserDataを参照してください。

(継承元 Control)
IDataBindingsAccessor.DataBindings

このメンバーの説明については、 DataBindingsを参照してください。

(継承元 Control)
IDataBindingsAccessor.HasDataBindings

このメンバーの説明については、 HasDataBindingsを参照してください。

(継承元 Control)
IExpressionsAccessor.Expressions

このメンバーの説明については、 Expressionsを参照してください。

(継承元 Control)
IExpressionsAccessor.HasExpressions

このメンバーの説明については、 HasExpressionsを参照してください。

(継承元 Control)
IParserAccessor.AddParsedSubObject(Object)

このメンバーの説明については、 AddParsedSubObject(Object)を参照してください。

(継承元 Control)

拡張メソッド

名前 説明
FindDataSourceControl(Control)

指定したコントロールのデータ コントロールに関連付けられているデータ ソースを返します。

FindFieldTemplate(Control, String)

指定したコントロールの名前付けコンテナー内の指定した列のフィールド テンプレートを返します。

FindMetaTable(Control)

格納されているデータ コントロールのメタテーブル オブジェクトを返します。

適用対象

こちらもご覧ください