IAdsHandle.TryRead Method

Reads the value synchronously data of the symbol, that is represented by the variable handle into the readBuffer.

Namespace:  TwinCAT.Ads
Assembly:  TwinCAT.Ads.Abstractions (in TwinCAT.Ads.Abstractions.dll) Version: 6.0.328+39e3229

Syntax

C#

AdsErrorCode TryRead(
    uint variableHandle,
    Memory<byte> readBuffer,
    out int readBytes
)

Parameters

variableHandle

Type: System.UInt32
The variable handle.

readBuffer

Type: System.Memory.Byte.
The read buffer/data

readBytes

Type: System.Int32.
Number of read bytes.

Return Value

Type: AdsErrorCode
The ADS error code.

Reference

IAdsHandle Interface

TwinCAT.Ads Namespace