AdsClient.ReadDataTypeAsync Method

read data type as an asynchronous operation.

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

Syntax

C#

public Task<ResultValue<IDataType>> ReadDataTypeAsync(
    string typeName,
    CancellationToken cancel
)

Parameters

typeName

Type: System.String
Name of the data type.

cancel

Type: System.Threading.CancellationToken
The cancel token.

Return Value

Type: Task.ResultValue.IDataType..
A task that represents the asynchronous 'ReadDataType' operation. The ResultValue.TValue. parameter contains the read value (Value) and the ErrorCode after execution.

Implements

IAdsSymbolicAccess.ReadDataTypeAsync(String, CancellationToken)

Exceptions

Exception

Condition

ArgumentOutOfRangeException

typeName

ObjectDisposedException

ClientNotConnectedException

Reference

AdsClient Class

TwinCAT.Ads Namespace

IAdsSymbolicAccess.ReadDataType(String)

IAdsSymbolicAccess.TryReadDataType(String, IDataType.)