StartPage.GetStartPage Method

Returns the initialization page for the specified page.

Namespace:  System.Web.WebPages
Assembly:  System.Web.WebPages (in System.Web.WebPages.dll)

public static function GetStartPage(
	page : WebPageRenderingBase, 
	fileName : String, 
	supportedExtensions : IEnumerable<String>
) : WebPageRenderingBase

Parameters

page
Type: System.Web.WebPages.WebPageRenderingBase
The page.
fileName
Type: System.String
The file name of the page.
supportedExtensions
Type: System.Collections.Generic.IEnumerable(String)
The collection of file-name extensions that can contain ASP.NET Razor syntax, such as "cshtml" and "vbhtml".

Return Value

Type: System.Web.WebPages.WebPageRenderingBase
The _AppStart page if the _AppStart page exists. If the _AppStart page cannot be found, returns the _PageStart page if a _PageStart page exists. If the _AppStart and _PageStart pages cannot be found, returns page.

ExceptionCondition
ArgumentNullException

Either page or fileName are a null reference (Nothing in Visual Basic).

ArgumentException

supportedExtensions is a null reference (Nothing in Visual Basic) or empty.

Show: