---
Product: Aspose.PDF
Platform: go
Page Type: reference
Canonical URL: https://reference.aspose.org/pdf/go/checkboxfield
---

# CheckboxField

## Overview

`CheckboxField` is a type in Aspose.PDF FOSS for Go.
Inherits from: `fieldBase`.

CheckboxField is a checkbox with on/off state.

This type declares 6 methods for CheckboxField objects in Go programs.
Available methods include: `Checked`, `SetChecked`, `SetReadOnly`, `SetRequired`, `SetValue`, `Value`.
Public members are accessible to any Go application after installing the Aspose.PDF FOSS for Go package.

## Methods

| Signature | Description |
|-----------|-------------|
| `Value()` → `string` | Returns the value. |
| `SetValue(s: string)` → `error` | Sets the value value. |
| `Checked()` → `bool` | Returns the checked. |
| `SetChecked(v: bool)` | SetChecked sets the checkbox state. |
| `SetReadOnly(v: bool)` | Sets the read only value. |
| `SetRequired(v: bool)` | Sets the required value. |

## See Also

- [Aspose.PDF — Enterprise API Reference](https://reference.aspose.com/pdf/)