Venice
Purch::InsertEntProp
 
Inserts an entry proposal in the document.
 
void InsertEntProp (
    VARIANT vCode
)
 
Parameters
vCode
[in] A VARIANT stating the code of the entry proposal you want to insert. The type of this VARIANT determines the action to be taken by the SDK:
Subtype Action
VT_EMPTY If an entry proposal code for the corresponding document type is found in the supplier card, this value is used.
If no proposal code is found in the supplier card, the entry proposal for a blank code is used if it exists, otherwise no details are added.
BSTR (VT_BSTR) The given value is used if it exists, otherwise an exception is thrown.
 
Remarks
The details of the entry proposal are added after the existing details.
 
See Also
CreatePurch
Handling accounting documents using the SDK
PrepareDocument
GetNumDetails
WriteDocument
 
Samples
 
C++
 
// Insert an entry proposal with code 'PRP01' in the document.
int iNumDets;

pPurch->PrepareDocument (paInsert);

// Fill the necessary header data

iNumDets = pPurch->GetNumDetails ();

pPurch->InsertEntProp ("PRP01");

for (int iNew = pPurch->GetNumDetails (); iNew > iNumDets; iNew--)
{
    // Add necessary data to the details of the proposal
}

pPurch->WriteDocument (rmFullReport);

C#
 
// Insert an entry proposal with code 'PRP01' in the document.
int iNumDets;

oPurch.PrepareDocument (ePrepareAction.paInsert);

// Fill the necessary header data

iNumDets = oPurch.GetNumDetails ();

oPurch.InsertEntProp ("PRP01");

for (int iNew = oPurch.GetNumDetails (); iNew > iNumDets; iNew--)
{
    // Add necessary data to the details of the proposal
}

oPurch.WriteDocument (eReportMode.rmFullReport);

VBS
 
' Insert an entry proposal with code 'PRP01' in the document.
Dim iNumDets, iNew

Call oPurch.PrepareDocument(paInsert)

' Fill the necessary header data

iNumDets = oPurch.GetNumDetails()

Call oPurch.InsertEntProp("PRP01")

For iNew = oPurch.GetNumDetails() To iNumDets
    ' Add necessary data to the details of the proposal
Next

Call oPurch.WriteDocument(rmFullReport)

VB.NET
 
' Insert an entry proposal with code 'PRP01' in the document.
Dim sNumDets, sNew As Short

oPurch.PrepareDocument(ePrepareAction.paInsert)

' Fill the necessary header data

sNumDets = oPurch.GetNumDetails()

oPurch.InsertEntProp("PRP01")

For sNew = oPurch.GetNumDetails() To sNumDets
    ' Add necessary data to the details of the proposal
Next

oPurch.WriteDocument(eReportMode.rmFullReport)