IControlPanel.GetPage(Type) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Retrieves the feature that has the specified type.
public:
Microsoft::Web::Management::Client::ModulePageInfo ^ GetPage(Type ^ pageType);
public Microsoft.Web.Management.Client.ModulePageInfo GetPage (Type pageType);
abstract member GetPage : Type -> Microsoft.Web.Management.Client.ModulePageInfo
Public Function GetPage (pageType As Type) As ModulePageInfo
Parameters
Returns
A ModulePageInfo object that represents the feature that has the specified page type, or null
if there is no matching feature.
Examples
The following example sends several feature details to the trace listener.
IControlPanel controlPanel =
(IControlPanel)GetService(typeof(IControlPanel));
ModulePageInfo pi =
controlPanel.GetPage(typeof(DemoPage));
if (pi == null)
return;
Trace.WriteLine("AssociatedModule.ModuleInfo.Name: \"" +
pi.AssociatedModule.ModuleInfo.Name + "\"");
Trace.WriteLine("Description: \""
+ pi.Description + "\"");
Trace.WriteLine("IsEnabled: \""
+ pi.IsEnabled.ToString() + "\"");
Trace.WriteLine("LongDescription: \""
+ pi.LongDescription + "\"");
Trace.WriteLine("Title \"" + pi.Title + "\"");
Trace.WriteLine("PageType.Assembly.FullName: \"" +
pi.PageType.Assembly.FullName + "\"");