# Add button component The page describes how to add button component to a document using GroupDocs.Annotation for .NET. Button component creates a button component as shown in the picture below: ![](https://docs.groupdocs.com/annotation/net/images/add-button-component.png) You can specify the following properties of the [ButtonComponent](https://reference.groupdocs.com/net/annotation/groupdocs.annotation.models.formatspecificcomponents.pdf/buttoncomponent) class: * [Box](https://reference.groupdocs.com/annotation/net/groupdocs.annotation.models.formatspecificcomponents.pdf/buttoncomponent/properties/box) defines the annotation position * [PenColor](https://reference.groupdocs.com/annotation/net/groupdocs.annotation.models.formatspecificcomponents.pdf/buttoncomponent/properties/pencolor) defines the frame color To add a button component, follow these steps: 1. Instantiate the [Annotator](https://reference.groupdocs.com/net/annotation/groupdocs.annotation/annotator) class. Specify the input document path or stream. 2. Instantiate the [ButtonComponent](https://reference.groupdocs.com/net/annotation/groupdocs.annotation.models.formatspecificcomponents.pdf/buttoncomponent) class. Specify the appropriate properties (position, page number, etc). 3. Call the [Add](https://reference.groupdocs.com/net/annotation/groupdocs.annotation/annotator/methods/add) method. Specify the [ButtonComponent](https://reference.groupdocs.com/net/annotation/groupdocs.annotation.models.formatspecificcomponents.pdf/buttoncomponent) class. 4. Call the [Save](https://reference.groupdocs.com/net/annotation/groupdocs.annotation/annotator/methods/save/index) method. Specify the output document path or stream. The following code snippet shows how to add [ButtonComponent](https://reference.groupdocs.com/net/annotation/groupdocs.annotation.models.formatspecificcomponents.pdf/cropdowncomponent) to the document: {{< tabs "example1">}} {{< tab "C#" >}} ```csharp using (Annotator annotator = new Annotator("input.pdf")) { ButtonComponent button = new ButtonComponent { CreatedOn = DateTime.Now, Style = BorderStyle.Dashed, Message = "This is button component", BorderColor = 1422623, PenColor = 14527697, ButtonColor = 10832612, PageNumber = 0, BorderWidth = 12, Box = new Rectangle(100, 300, 90, 30), Replies = new List { new Reply { Comment = "First comment", RepliedOn = DateTime.Now }, new Reply { Comment = "Second comment", RepliedOn = DateTime.Now } } }; annotator.Add(button); annotator.Save("result.pdf"); } ``` {{< /tab >}} {{< /tabs >}}