How to: Add a PDF Viewer to the WinForms Application at Design Time
The following example demonstrates how to add the PdfViewer to a form at design time.
To add a PDF Viewer to the Windows Forms application at design time, do the following.
- Run Microsoft® Visual Studio® 2012, 2013, 2015 or 2017.
Start a new project (by pressing CTRL+SHIFT+N) and create a new Windows Forms Application.
Open the Visual Studio designer and press CTRL+ALT+X to run the Toolbox. Expand the DX.18.2: Common Controls category, and drop the PdfViewer control onto the main form of the application.
Click the PdfViewer’s smart tag to invoke its actions list. In the actions list, click the Dock in parent container link. This allows the PDF Viewer to occupy all of the available spaces on the form.
After docking the PDF Viewer, it will appear as follows.
The PdfViewer is now added to your application.