PDF Creator Pilot documentation |
Download CHM version of this manual. |
|
![]() ![]() Collapse AllThis method creates a checkbox control in a PDF document.
|
| LONG PDFPAGE_CreateControl_Checkbox ( BSTR checkboxName, LONG left, LONG top, LONG right, LONG bottom ) |
Parameters
checkboxName
Name of the control
left
X coordinate of the ltop-left corner of the bounding rectangle
top
Y coordinate of the ltop-left corner of the bounding rectangle
right
X coordinate of the bottom-right corner of the bounding rectangle
bottom
Y coordinate of the bottom-right corner of the bounding rectangle
Return value
Index of the checkbox
Remarks
This method creates a checkbox control with name checkboxName on the current PDF page in an area bounded by the coordinates given.
The return value is an annotation/control identifier in document's annotations collection and can be used in AddControlToAction, CurrentAnnotationIndex.
Equivalent in new interface: IPDFDocument4::AddCheckBox.
Example
Creating a Checkbox
Delphi
[copy to clipboard]
{ PDF object is supposed to be created }
PDF.BeginDoc;
PDF.PDFPAGE_CreateControl_Checkbox('ch1', 10, 10, 110, 23);
PDF.PDFANNOTATION_Caption := 'Caption';
PDF.EndDoc;
C/C++
[copy to clipboard]
// PDF object is supposed to be created
PDF->BeginDoc();
PDF->PDFPAGE_CreateControl_Checkbox("ch1", 10, 10, 110, 23);
PDF->PDFANNOTATION_Caption = "Caption";
PDF->EndDoc();
C#
[copy to clipboard]
// PDF object is supposed to be created
PDF.BeginDoc();
PDF.PDFPAGE_CreateControl_Checkbox("ch1", 10, 10, 110, 23);
PDF.PDFANNOTATION_Caption = "Caption";
PDF.EndDoc();
Visual Basic
[copy to clipboard]
' PDF object is supposed to be created PDF.BeginDoc PDF.PDFPAGE_CreateControl_Checkbox "ch1", 10, 10, 110, 23 PDF.PDFANNOTATION_Caption = "Caption" PDF.EndDoc
See Also


