TemplateStack.Push Method
Inserts a template file at the top of the stack in the specified HTTP context.
Namespace: System.Web.WebPages
Assembly: System.Web.WebPages (in System.Web.WebPages.dll)
Syntax
'Declaration
Public Shared Sub Push ( _
httpContext As HttpContextBase, _
templateFile As ITemplateFile _
)
'Usage
Dim httpContext As HttpContextBase
Dim templateFile As ITemplateFile
TemplateStack.Push(httpContext, templateFile)
public static void Push(
HttpContextBase httpContext,
ITemplateFile templateFile
)
public:
static void Push(
HttpContextBase^ httpContext,
ITemplateFile^ templateFile
)
static member Push :
httpContext:HttpContextBase *
templateFile:ITemplateFile -> unit
public static function Push(
httpContext : HttpContextBase,
templateFile : ITemplateFile
)
Parameters
- httpContext
Type: System.Web.HttpContextBase
The HTTP context that contains the stack that stores the template files.
- templateFile
Type: System.Web.WebPages.ITemplateFile
The template file to push onto the specified stack.
Exceptions
Exception | Condition |
---|---|
ArgumentNullException | httpContext or templateFile are null reference (Nothing in Visual Basic). |
Remarks
This method returns no value.