PagesSection.Controls プロパティ
アセンブリ: System.Web (system.web.dll 内)

TagPrefixInfo オブジェクトの TagPrefixCollection。

TagPrefixInfo オブジェクトは、ASP.NET ページ上の Register ディレクティブ (<%@ Register %>) に対応します。Register ディレクティブを使用して、ユーザー コントロールのタグ プレフィックスを指定できます。

Controls プロパティを使用する方法を次のコード例に示します。
' Get all current Controls in the collection. Dim j As Int32 For j = 0 To pagesSection.Controls.Count - 1 Console.WriteLine("Control {0}:", j) Console.WriteLine(" TagPrefix = '{0}' ", _ pagesSection.Controls(j).TagPrefix) Console.WriteLine(" TagName = '{0}' ", _ pagesSection.Controls(j).TagName) Console.WriteLine(" Source = '{0}' ", _ pagesSection.Controls(j).Source) Console.WriteLine(" Namespace = '{0}' ", _ pagesSection.Controls(j).Namespace) Console.WriteLine(" Assembly = '{0}' ", _ pagesSection.Controls(j).Assembly) Next ' Create a new TagPrefixInfo object. Dim tagPrefixInfo As System.Web.Configuration.TagPrefixInfo = _ New System.Web.Configuration.TagPrefixInfo("MyCtrl", "MyNameSpace", "MyAssembly", "MyControl", "MyControl.ascx") ' Execute the Add Method. pagesSection.Controls.Add(tagPrefixInfo) ' Add a TagPrefixInfo object using a constructor. pagesSection.Controls.Add( _ New System.Web.Configuration.TagPrefixInfo( _ "MyCtrl", "MyNameSpace", "MyAssembly", "MyControl", _ "MyControl.ascx"))
// Get all current Controls in the collection. for (int i = 0; i < pagesSection.Controls.Count; i++) { Console.WriteLine("Control {0}:", i); Console.WriteLine(" TagPrefix = '{0}' ", pagesSection.Controls[i].TagPrefix); Console.WriteLine(" TagName = '{0}' ", pagesSection.Controls[i].TagName); Console.WriteLine(" Source = '{0}' ", pagesSection.Controls[i].Source); Console.WriteLine(" Namespace = '{0}' ", pagesSection.Controls[i].Namespace); Console.WriteLine(" Assembly = '{0}' ", pagesSection.Controls[i].Assembly); } // Create a new TagPrefixInfo object. System.Web.Configuration.TagPrefixInfo tagPrefixInfo = new System.Web.Configuration.TagPrefixInfo("MyCtrl", "MyNameSpace", "MyAssembly", "MyControl", "MyControl.ascx"); // Execute the Add Method. pagesSection.Controls.Add(tagPrefixInfo); // Add a TagPrefixInfo object using a constructor. pagesSection.Controls.Add( new System.Web.Configuration.TagPrefixInfo( "MyCtrl", "MyNameSpace", "MyAssembly", "MyControl" , "MyControl.ascx"));

Windows 98, Windows 2000 SP4, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


Weblioに収録されているすべての辞書からPagesSection.Controls プロパティを検索する場合は、下記のリンクをクリックしてください。

- PagesSection.Controls プロパティのページへのリンク