public AcroViewer() { int x = PdfAcroViewer.GetAcroPdfVersion(); x.GetType(); InitializeComponent(); viewer = new PdfAcroViewer(); this.host.Child = viewer; }
/// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { System.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(PdfViewer)); this.button1 = new System.Windows.Forms.Button(); this.button2 = new System.Windows.Forms.Button(); this.button3 = new System.Windows.Forms.Button(); this.button4 = new System.Windows.Forms.Button(); this.button5 = new System.Windows.Forms.Button(); this.button6 = new System.Windows.Forms.Button(); this.button7 = new System.Windows.Forms.Button(); this.acroViewer = new PdfSharp.Viewing.PdfAcroViewer(); this.SuspendLayout(); // // button1 // this.button1.Location = new System.Drawing.Point(4, 4); this.button1.Name = "button1"; this.button1.TabIndex = 1; this.button1.Text = "Load PDF"; this.button1.Click += new System.EventHandler(this.button1_Click); // // button2 // this.button2.Location = new System.Drawing.Point(84, 4); this.button2.Name = "button2"; this.button2.Size = new System.Drawing.Size(72, 23); this.button2.TabIndex = 2; this.button2.Text = "Outline"; this.button2.Click += new System.EventHandler(this.button2_Click); // // button3 // this.button3.Location = new System.Drawing.Point(164, 4); this.button3.Name = "button3"; this.button3.TabIndex = 3; this.button3.Text = "<<"; this.button3.Click += new System.EventHandler(this.button3_Click); // // button4 // this.button4.Location = new System.Drawing.Point(244, 4); this.button4.Name = "button4"; this.button4.TabIndex = 4; this.button4.Text = "<"; this.button4.Click += new System.EventHandler(this.button4_Click); // // button5 // this.button5.Location = new System.Drawing.Point(324, 4); this.button5.Name = "button5"; this.button5.TabIndex = 5; this.button5.Text = ">"; this.button5.Click += new System.EventHandler(this.button5_Click); // // button6 // this.button6.Location = new System.Drawing.Point(404, 4); this.button6.Name = "button6"; this.button6.TabIndex = 6; this.button6.Text = ">>"; this.button6.Click += new System.EventHandler(this.button6_Click); // // button7 // this.button7.Location = new System.Drawing.Point(484, 4); this.button7.Name = "button7"; this.button7.TabIndex = 7; this.button7.Text = "FullPage"; this.button7.Click += new System.EventHandler(this.button7_Click); // // acroViewer // this.acroViewer.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); this.acroViewer.Location = new System.Drawing.Point(0, 34); this.acroViewer.Name = "acroViewer"; this.acroViewer.Size = new System.Drawing.Size(692, 432); this.acroViewer.TabIndex = 8; // // PdfViewer // this.AutoScaleBaseSize = new System.Drawing.Size(5, 13); this.ClientSize = new System.Drawing.Size(692, 466); this.Controls.Add(this.acroViewer); this.Controls.Add(this.button7); this.Controls.Add(this.button6); this.Controls.Add(this.button5); this.Controls.Add(this.button4); this.Controls.Add(this.button3); this.Controls.Add(this.button2); this.Controls.Add(this.button1); this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); this.Name = "PdfViewer"; this.Text = "Sample PDF Viewer based on Adobe Reader ActiveX Control"; this.ResumeLayout(false); }