Skip to main content

Documentation Index

Fetch the complete documentation index at: https://notevil.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

diagGetTargetCount

Valid for: CANoe DE

Function Syntax

long diagGetTargetCount();

Description

Returns the number /n/ of possible diagnostic targets configured. For indices /i/ with 0 ≤ i ≤ n you can retrieve the target qualifier with DiagGetTargetQualifier. Note: Diagnostic descriptions that cannot work as diagnostic targets are not counted, e.g. descriptions configured as interpretation only are ignored.

Parameters

Return Values

Error code or number of diagnostic targets.

Example

long i;
char ecuQual[100];
i = diagGetTargetCount();
while( i-- > 0)
{
   diagGetTargetQualifier( i, ecuQual, elcount(ecuQual));
   write( "Target %d: %s", i, ecuQual);
}