Question:I need to write a program that displays a PDF which a third-party supplies. I need to insert text data in to the form before displaying it to the user. I do have the option to convert the PDF in to another format, but it has to look exactly like the original PDF. C++ is the preferred language of choice, but other languages can be investigated (e.g. C#). It need to work on a Windows desktop machine.What libraries, tools, strategies, or other programming languages do you suggest investigate to accomplish this task? Is there any solution on VeryPDF?
Answer: According to your needs, maybe you can have a free trial of this software:VeryPDF PDF Editor Toolkit, by which you can add text, image to PDF according to the position. Meanwhile it also allows you to do following options like creating PDF, converting images to PDF, merging PDF and splitting PDF together with C++, VB, Delphi, ASP, and .NET. Please check more related information of this software on homepage, in the following part, let us check how to use this software.
Step 1. Free download PDF Editor Toolkit
- When downloading finishes, this is a zip file. Please unzip it and then you can check related elements and call it from C# or others.
- There are two versions of this software: normal version and professional version. Please check their differences on comparison tab. Then choose the proper version according to your needs.
Step 2. Add text to PDF.
- The VeryAddTextEx function writes a character string at the specified location, using the currently selected font, text color,
if x = y = -1, indicate the text string will be drawing at current text position, default text position is (64, 64).
- There are some parameters for your reference:
Parameters –> Id
Returned by VeryCreate or VeryOpen function.
x—> Specifies the logical x-coordinate of the reference point that the system uses to align the string, the x-coordinate will moved automatically.
y –> Specifies the logical y-coordinate of the reference point that the system uses to align the string, the y-coordinate will moved automatically.
string –> Pointer to the string to be drawn, this string may include "\n" symbol
color –> Set text color, you may use RGB macro to combine this value.
Return Value—> Nonzero if it is successful; otherwise, it is zero.