OpenFile Method

VirtualPathProvider.OpenFile Method (String)

 

Returns a stream from a virtual file.

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

static member OpenFile : 
        virtualPath:string -> Stream

Parameters

virtualPath
Type: System.String

The path to the virtual file.

Return Value

Type: System.IO.Stream

A read-only Stream object for the specified virtual file or resource.

The OpenFile method is a convenience method that enables you to get a stream from a virtual file without creating a VirtualPathProvider instance.

.NET Framework
Available since 2.0
Return to top
Show:
© 2016 Microsoft