Class PdfCheckBoxStyle
Specifies the style for a check box field.
Inheritance
System.Object
PdfCheckBoxStyle
Namespace: Syncfusion.Pdf.Interactive
Assembly: Syncfusion.Pdf.NET.dll
Syntax
public sealed class PdfCheckBoxStyle : Enum
Remarks
The default value is Check.
Examples
//Create a new PDf document
PdfDocument document = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = document.Pages.Add();
//Create a check box
PdfCheckBoxField checkBox = new PdfCheckBoxField(page, "C#.NET");
checkBox.Bounds = new RectangleF(100, 290, 20, 20);
// Add the check box field in form`s field collection
document.Form.Fields.Add(checkBox);
checkBox.HighlightMode = PdfHighlightMode.Push;
checkBox.BorderStyle = PdfBorderStyle.Beveled;
// Set the check style
checkBox.Style = PdfCheckBoxStyle.Star;
checkBox.Checked = true;
document.Save("Form.pdf");
document.Close(true);
'Create a new PDf document
Dim document As PdfDocument = New PdfDocument()
'Creates a new page and adds it as the last page of the document
Dim page As PdfPage = document.Pages.Add()
'Create a check box
Dim checkBox As PdfCheckBoxField = New PdfCheckBoxField(page, "C#.NET")
checkBox.Bounds = New RectangleF(100, 290, 20, 20)
' Add the check box field in form`s field collection
document.Form.Fields.Add(checkBox)
checkBox.HighlightMode = PdfHighlightMode.Push
checkBox.BorderStyle = PdfBorderStyle.Beveled
' Set the check style
checkBox.Style = PdfCheckBoxStyle.Star
checkBox.Checked = True
document.Save("Form.pdf")
document.Close(True)
Fields
Check
A check mark is used for the checked state.
Declaration
public const PdfCheckBoxStyle Check
Field Value
Type |
---|
PdfCheckBoxStyle |
Circle
A circle is used for the checked state.
Declaration
public const PdfCheckBoxStyle Circle
Field Value
Type |
---|
PdfCheckBoxStyle |
Cross
A cross is used for the checked state.
Declaration
public const PdfCheckBoxStyle Cross
Field Value
Type |
---|
PdfCheckBoxStyle |
Diamond
A diamond symbol is used for the checked state.
Declaration
public const PdfCheckBoxStyle Diamond
Field Value
Type |
---|
PdfCheckBoxStyle |
Square
A square is used for the checked state.
Declaration
public const PdfCheckBoxStyle Square
Field Value
Type |
---|
PdfCheckBoxStyle |
Star
A star is used for the checked state.
Declaration
public const PdfCheckBoxStyle Star
Field Value
Type |
---|
PdfCheckBoxStyle |