OpenExisting Method (String, MemoryMappedFileRights)
Collapse the table of content
Expand the table of content

MemoryMappedFile.OpenExisting Method (String, MemoryMappedFileRights)

.NET Framework (current version)
 

Opens an existing memory-mapped file that has the specified name and access rights in system memory.

Namespace:   System.IO.MemoryMappedFiles
Assembly:  System.Core (in System.Core.dll)

static member OpenExisting : 
        mapName:string *
        desiredAccessRights:MemoryMappedFileRights -> MemoryMappedFile

Parameters

mapName
Type: System.String

The name of the memory-mapped file to open.

desiredAccessRights
Type: System.IO.MemoryMappedFiles.MemoryMappedFileRights

One of the enumeration values that specifies the access rights to apply to the memory-mapped file.

Return Value

Type: System.IO.MemoryMappedFiles.MemoryMappedFile

A memory-mapped file that has the specified characteristics.

Exception Condition
ArgumentException

mapName is an empty string.

ArgumentNullException

mapName is null.

ArgumentOutOfRangeException

desiredAccessRights is not a valid MemoryMappedFileRights enumeration value.

FileNotFoundException

The file specified for mapName does not exist.

Universal Windows Platform
Available since 10
.NET Framework
Available since 4.0
Return to top
Show:
© 2016 Microsoft