Xojo.Core.MemoryBlock.Right

From Xojo Documentation

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)