op.document.addBarcode
From PDF XChange PDF SDK
Overview
The operation allows to add a barcode on to the document's page as a stamp annotation or as a part of the page's content.
Parameters
| Name | Type | Description |
|---|---|---|
| Input | IUnknown | Specifies the IPXC_Document where the barcode should be inserted into. |
| Output | IUnknown | Returns IPXC_Annotation if the barcode was placed as a stamp annotation or INumArray if the barcode was placed as a part of the page's content. |
| Options | Dictionary | Dictionary with options of the operation. |
Sample
//C#
private void AddBarcode(PDFXEdit.IPXV_Document Doc, PDFXEdit.IPXV_Inst Inst)
{
int nID = Inst.Str2ID("op.document.addBarcode", false);
PDFXEdit.IOperation Op = Inst.CreateOp(nID);
var input = Op.Params.Root["Input"];
input.v = Doc.CoreDoc;
PDFXEdit.ICabNode options = Op.Params.Root["Options"];
options["Pos.left"].v = 100;
options["Pos.right"].v = 200;
options["Pos.bottom"].v = 100;
options["Pos.top"].v = 200;
options["AsStamp"].v = false;
options["ECCLevel"].v = 4;
options["Data"].v = "This is a test barcode data";
Op.Do();
}