Click or drag to resize

HttpRequestEventArgsReadFile Method

Reads the specified file from the document folder of the HttpServer.

Namespace:  Sfs2X.WebSocketSharp.Server
Assembly:  SmartFox2X (in SmartFox2X.dll) Version: 1.8.0.0 (1.8.0)
Syntax
C#
public byte[] ReadFile(
	string path
)

Parameters

path
Type: SystemString
A String that represents a virtual path to find the file from the document folder.

Return Value

Type: Byte

An array of Byte or if it fails.

That array receives the contents of the file.

Exceptions
ExceptionCondition
ArgumentNullExceptionpath is .
ArgumentException

path is an empty string.

-or-

path contains "..".

See Also