ViewHierarchyUtility.GetViewStartLocations(String) 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.
Gets the view start locations that are applicable to the specified path.
public:
static System::Collections::Generic::IEnumerable<System::String ^> ^ GetViewStartLocations(System::String ^ applicationRelativePath);
public static System.Collections.Generic.IEnumerable<string> GetViewStartLocations (string applicationRelativePath);
static member GetViewStartLocations : string -> seq<string>
Public Shared Function GetViewStartLocations (applicationRelativePath As String) As IEnumerable(Of String)
Parameters
- applicationRelativePath
- String
The application relative path of the file to locate
_ViewStart
s for.
Returns
A sequence of paths that represent potential view start locations.
Remarks
This method returns paths starting from the directory of applicationRelativePath
and moves upwards until it hits the application root. e.g. /Views/Home/View.cshtml -> [ /Views/Home/_ViewStart.cshtml, /Views/_ViewStart.cshtml, /_ViewStart.cshtml ]
Applies to
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for