Xojo.Core.MemoryBlock.Right

From Xojo Documentation

Revision as of 17:26, 11 August 2019 by Gperlman (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Method

Xojo.Core.MemoryBlock.Right(bytes As UInteger) As Xojo.Core.MemoryBlock

Supported for all project types and targets.

Gets the bytes from the end of the MemoryBlock.

Exceptions

Sample Code

Get the last two bytes of a MemoryBlock:

Var bytes() As Byte
bytes.Append(&h0a)
bytes.Append(&h0b)
bytes.Append(&h0c)

Var data As New Xojo.Core.MemoryBlock(bytes)
Var mb As Xojo.Core.MemoryBlock = data.Right(2)