Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

SafeBuffer::Read<T> Method (UInt64)

.NET Framework (current version)
 

Reads a value type from memory at the specified offset.

This API is not CLS-compliant.

Namespace:   System.Runtime.InteropServices
Assembly:  mscorlib (in mscorlib.dll)

public:
generic<typename T>
where T : value struct, gcnew()
[CLSCompliantAttribute(false)]
T Read(
	unsigned long long byteOffset
)

Parameters

byteOffset
Type: System::UInt64

The location from which to read the value type. You may have to consider alignment issues.

Return Value

Type: T

The value type that was read from memory.

Type Parameters

T

The value type to read.

Exception Condition
InvalidOperationException

The Initialize method has not been called.

Universal Windows Platform
Available since 8
.NET Framework
Available since 4.0
Portable Class Library
Supported in: portable .NET platforms
Windows Phone
Available since 8.1
Return to top
Show:
© 2017 Microsoft