Class PdfLoadedXfaCheckBoxField
Represents the loaded XFA check box field.
Inheritance
System.Object
PdfLoadedXfaCheckBoxField
Inherited Members
Namespace: Syncfusion.Pdf.Xfa
Assembly: Syncfusion.Pdf.Portable.dll
Syntax
public class PdfLoadedXfaCheckBoxField : PdfLoadedXfaStyledField
Examples
//Load the existing PDF document
PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf");
//Load the existing XFA form
PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm;
//Get the loaded check box field.
PdfLoadedXfaCheckBoxField loadedCheckBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["checkBox[0]"] as PdfLoadedXfaCheckBoxField;
//Check the check box
loadedCheckBox.IsChecked = true;
//Save the document
loadedDocument.Save("output.pdf");
//Close the document
loadedDocument.Close();
'Load the existing PDF document
Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf")
'Load the existing XFA form
Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm
'Get the loaded check box field.
Dim loadedCheckBox As PdfLoadedXfaCheckBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("checkBox[0]"), PdfLoadedXfaCheckBoxField)
'Check the check box
loadedCheckBox.IsChecked = True
'Save the document
loadedDocument.Save("output.pdf")
'Close the document
loadedDocument.Close()
Constructors
PdfLoadedXfaCheckBoxField()
Declaration
public PdfLoadedXfaCheckBoxField()
Properties
CheckBoxAppearance
Gets or sets the appearance of the check box
Declaration
public PdfXfaCheckBoxAppearance CheckBoxAppearance { get; set; }
Property Value
Type |
---|
PdfXfaCheckBoxAppearance |
Examples
//Load the existing PDF document
PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf");
//Load the existing XFA form
PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm;
//Get the loaded check box field.
PdfLoadedXfaCheckBoxField loadedCheckBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["checkBox[0]"] as PdfLoadedXfaCheckBoxField;
//Check the check box
loadedCheckBox.IsChecked = true;
//Get the check box appearance.
PdfXfaCheckBoxAppearance appearance = loadedCheckBox.CheckBoxAppearance;
//Save the document
loadedDocument.Save("output.pdf");
//Close the document
loadedDocument.Close();
'Load the existing PDF document
Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf")
'Load the existing XFA form
Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm
'Get the loaded check box field.
Dim loadedCheckBox As PdfLoadedXfaCheckBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("checkBox[0]"), PdfLoadedXfaCheckBoxField)
'Check the check box
loadedCheckBox.IsChecked = True
'Get the check box appearance.
Dim appearance As PdfXfaCheckBoxAppearance = loadedCheckBox.CheckBoxAppearance
'Save the document
loadedDocument.Save("output.pdf")
'Close the document
loadedDocument.Close()
CheckBoxSize
Gets or sets the size of the check box
Declaration
public float CheckBoxSize { get; set; }
Property Value
Type |
---|
System.Single |
Examples
//Load the existing PDF document
PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf");
//Load the existing XFA form
PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm;
//Get the loaded check box field.
PdfLoadedXfaCheckBoxField loadedCheckBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["checkBox[0]"] as PdfLoadedXfaCheckBoxField;
//Check the check box
loadedCheckBox.IsChecked = true;
//Get the checkbox size.
float checkBoxSize = loadedCheckBox.CheckBoxSize;
//Save the document
loadedDocument.Save("output.pdf");
//Close the document
loadedDocument.Close();
'Load the existing PDF document
Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf")
'Load the existing XFA form
Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm
'Get the loaded check box field.
Dim loadedCheckBox As PdfLoadedXfaCheckBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("checkBox[0]"), PdfLoadedXfaCheckBoxField)
'Check the check box
loadedCheckBox.IsChecked = True
'Get the checkbox size.
Dim checkBoxSize As Single = loadedCheckBox.CheckBoxSize
'Save the document
loadedDocument.Save("output.pdf")
'Close the document
loadedDocument.Close()
CheckedStyle
Gets or sets the checked styles of the check box
Declaration
public PdfXfaCheckedStyle CheckedStyle { get; set; }
Property Value
Type |
---|
PdfXfaCheckedStyle |
Examples
//Load the existing PDF document
PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf");
//Load the existing XFA form
PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm;
//Get the loaded check box field.
PdfLoadedXfaCheckBoxField loadedCheckBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["checkBox[0]"] as PdfLoadedXfaCheckBoxField;
//Check the check box
loadedCheckBox.IsChecked = true;
//Get the checked style.
PdfXfaCheckedStyle style = loadedCheckBox.CheckedStyle;
//Save the document
loadedDocument.Save("output.pdf");
//Close the document
loadedDocument.Close();
'Load the existing PDF document
Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf")
'Load the existing XFA form
Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm
'Get the loaded check box field.
Dim loadedCheckBox As PdfLoadedXfaCheckBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("checkBox[0]"), PdfLoadedXfaCheckBoxField)
'Check the check box
loadedCheckBox.IsChecked = True
'Get the checked style.
Dim style As PdfXfaCheckedStyle = loadedCheckBox.CheckedStyle
'Save the document
loadedDocument.Save("output.pdf")
'Close the document
loadedDocument.Close()
IsChecked
Gets or sets a value indicating whether this is checked or not
Declaration
public bool IsChecked { get; set; }
Property Value
Type |
---|
System.Boolean |
Examples
//Load the existing PDF document
PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf");
//Load the existing XFA form
PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm;
//Get the loaded check box field.
PdfLoadedXfaCheckBoxField loadedCheckBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["checkBox[0]"] as PdfLoadedXfaCheckBoxField;
//Check the check box
loadedCheckBox.IsChecked = true;
//Save the document
loadedDocument.Save("output.pdf");
//Close the document
loadedDocument.Close();
'Load the existing PDF document
Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf")
'Load the existing XFA form
Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm
'Get the loaded check box field.
Dim loadedCheckBox As PdfLoadedXfaCheckBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("checkBox[0]"), PdfLoadedXfaCheckBoxField)
'Check the check box
loadedCheckBox.IsChecked = True
'Save the document
loadedDocument.Save("output.pdf")
'Close the document
loadedDocument.Close()