Edit

Share via


IDebugMemoryBytes2::WriteAt

Writes the specified number of bytes of memory, starting at the specified address.

Syntax

int WriteAt(
   IDebugMemoryContext2 pStartContext,
   uint                 dwCount,
   byte[]               rgbMemory
);

Parameters

pStartContext
[in] The IDebugMemoryContext2 object that specifies where to start writing bytes.

dwCount
[in] The number of bytes to write.

rgbMemory
[in] The bytes to write. This array is assumed to be at least dwCount bytes in size.

Return Value

If successful, returns S_OK; otherwise, returns S_FALSE if not all bytes could be written or returns an error code (typically E_FAIL).

Remarks

If the starting address is not within the memory window represented by this IDebugMemoryBytes2 object, no writing occurs and an error code of E_FAIL is returned — even if the amount to write overlaps into the memory space.

See also