NativeFileIOOpenFileHandle Method (String, FileAccess, FileShare, FileMode, UInt32) |
Calls Win32 API CreateFile() function and encapsulates returned handle in a SafeFileHandle object.
Namespace:
Arsenal.ImageMounter.IO
Assembly:
Arsenal.ImageMounter (in Arsenal.ImageMounter.dll) Version: 1.0.0.0 (3.4.140.0)
Syntax public static SafeFileHandle OpenFileHandle(
string FileName,
FileAccess DesiredAccess,
FileShare ShareMode,
FileMode CreationDisposition,
uint Options
)
Public Shared Function OpenFileHandle (
FileName As String,
DesiredAccess As FileAccess,
ShareMode As FileShare,
CreationDisposition As FileMode,
Options As UInteger
) As SafeFileHandle
public:
static SafeFileHandle^ OpenFileHandle(
String^ FileName,
FileAccess DesiredAccess,
FileShare ShareMode,
FileMode CreationDisposition,
unsigned int Options
)
static member OpenFileHandle :
FileName : string *
DesiredAccess : FileAccess *
ShareMode : FileShare *
CreationDisposition : FileMode *
Options : uint32 -> SafeFileHandle
Parameters
- FileName
- Type: SystemString
Name of file to open. - DesiredAccess
- Type: System.IOFileAccess
File access to request. - ShareMode
- Type: System.IOFileShare
Share mode to request. - CreationDisposition
- Type: System.IOFileMode
Open/creation mode. - Options
- Type: SystemUInt32
Specifies whether to request overlapped I/O.
Return Value
Type:
SafeFileHandleSee Also