using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; namespace WinFormsApp { public partial class FormPreviewPDF : Form { public string src { get; set; } public FormPreviewPDF() { InitializeComponent(); } private void buttonPrint_Click(object sender, EventArgs e) { DialogResult = DialogResult.OK; Close(); } private void FormPreviewPDF_Load(object sender, EventArgs e) { axAcropdf.src = src; axAcropdf.LoadFile(src); axAcropdf.setView("Fit"); axAcropdf.Show(); } private void buttonCancel_Click(object sender, EventArgs e) { DialogResult = DialogResult.Cancel; Close(); } private void axAcropdf_Enter(object sender, EventArgs e) { } } }