Share via


WebRazorHostFactory.CreateHost Method

This type/member supports the .NET Framework infrastructure and is not intended to be used directly from your code.

Creates a Razor host.

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

Syntax

'Declaration
Public Overridable Function CreateHost ( _
    virtualPath As String, _
    physicalPath As String _
) As WebPageRazorHost
'Usage
Dim instance As WebRazorHostFactory 
Dim virtualPath As String 
Dim physicalPath As String 
Dim returnValue As WebPageRazorHost 

returnValue = instance.CreateHost(virtualPath, _
    physicalPath)
public virtual WebPageRazorHost CreateHost(
    string virtualPath,
    string physicalPath
)
public:
virtual WebPageRazorHost^ CreateHost(
    String^ virtualPath, 
    String^ physicalPath
)
abstract CreateHost : 
        virtualPath:string * 
        physicalPath:string -> WebPageRazorHost  
override CreateHost : 
        virtualPath:string * 
        physicalPath:string -> WebPageRazorHost
public function CreateHost(
    virtualPath : String, 
    physicalPath : String
) : WebPageRazorHost

Parameters

  • virtualPath
    Type: System.String
    The virtual path to the target file.
  • physicalPath
    Type: System.String
    The physical path to the target file.

Return Value

Type: System.Web.WebPages.Razor.WebPageRazorHost
A razor host.

See Also

Reference

WebRazorHostFactory Class

System.Web.WebPages.Razor Namespace