Sndry::GetNumAnaDetails (Interface: Sndry)
 
Gets the number of analytical details for one accounting detail and analytical type.
 
SHORT GetNumAnaDetails (
    SHORT sAccIndex,
    enum eAnaEntType eAnaEntType
)
 
Parameters
sAccIndex
[in] The index of the detail line where the analytical detail line belongs to, starting from 0.
eAnaEntType
[in] A value of the 'eAnaEntType' enumeration.
 
Return value
A SHORT containing the number of analytical details of the current document.
 
Remarks
If the analytical option is not active in the dossier, this method returns 0.
 
See Also
CreateSndry
Handling accounting documents using the SDK
PrepareDocument
GetManualIndex
CancelDocument
 
Samples
 
C++
 
// Get the number of analytical details by centre of the first manual detail of the current document
short sManualIndex;

pSndry->PrepareDocument (paView);

sManualIndex = pSndry->GetManualIndex ();

if (sManualIndex != -1)
{
    short sNumAnaDets = pSndry->GetNumAnaDetails (sManualIndex, aetCent);
    
    if (sNumAnaDets != 0)
    {
        // Process data
    }
}

pSndry->CancelDocument ();

C#
 
// Get the number of analytical details by centre of the first manual detail of the current document
short sManualIndex;

oSndry.PrepareDocument (ePrepareAction.paView);

sManualIndex = oSndry.GetManualIndex ();

if (sManualIndex != -1)
{
    short sNumAnaDets = oSndry.GetNumAnaDetails (sManualIndex, eAnaEntType.aetCent);
    
    if (sNumAnaDets != 0)
    {
        // Process data
    }
}

oSndry.CancelDocument ();

VBS
 
' Get the number of analytical details by centre of the first manual detail of the current document
Dim sManualIndex

Call oSndry.PrepareDocument(paView)

sManualIndex = oSndry.GetManualIndex()

If sManualIndex <> -1 Then
    Dim sNumAnaDets
    
    sNumAnaDets = oSndry.GetNumAnaDetails(sManualIndex, aetCent)
    
    If sNumAnaDets <> 0 Then
        ' Process data
    End If
End If

Call oSndry.CancelDocument()

VB.NET
 
' Get the number of analytical details by centre of the first manual detail of the current document
Dim sManualIndex As Short

oSndry.PrepareDocument(ePrepareAction.paView)

sManualIndex = oSndry.GetManualIndex()

If sManualIndex <> -1 Then
    Dim sNumAnaDets As Short
    
    sNumAnaDets = oSndry.GetNumAnaDetails(sManualIndex, eAnaEntType.aetCent)
    
    If sNumAnaDets <> 0 Then
        ' Process data
    End If
End If

oSndry.CancelDocument()