Current filter:
                                You should refresh the page.
                                  • Hi,
                                    I am trying to add a text field to a current pdf document. i just want it to say Test in the top corner. I tried the following code but could not get it to function. Any help would be greatly appreciated.

                                          PdfDocumentProcessor documentProcessor = new PdfDocumentProcessor();
                                                documentProcessor.LoadDocument(labelLocation.Text );
                                                PdfAcroFormTextBoxField textBox = new PdfAcroFormTextBoxField("text box", 1, new PdfRectangle(230, 690, 280, 710));

                                                // Specify text box text, and appearance.
                                                textBox.Text = "Text Box";
                                                textBox.Appearance.BackgroundColor = new PdfRGBColor(0.8, 0.5, 0.3);
                                                textBox.Appearance.FontSize = 12;

                                                // Save the result document.

                                1 Solution

                                Creation Date Importance Sort by
                                I see that you are attempting to create an interactive form field - TextBox. Note that it's necessary to invoke the PdfDocumentProcessor.AddFormFields method with your PdfAcroFormTextBoxField object as a parameter to add your field to a document. Please review this article for more details - Creating Interactive Form.
                                However, I would like to clarify your end-goal. Do you really need to insert the form field or do you just want to add some new text to a document? If you want to add a text, please review articles provided on this page - PDF Graphics. They describe how to add a graphics to a document page.
                                I hope that you find this information useful.