PDFsharp & MigraDoc Foundation https://forum.pdfsharp.net/ |
|
Draw directly on handle https://forum.pdfsharp.net/viewtopic.php?f=2&t=1589 |
Page 1 of 1 |
Author: | bastianonm [ Tue Mar 22, 2011 9:12 am ] |
Post subject: | Draw directly on handle |
Hi, I need to create pdf and draw from a vb6 application. I belive the only way to succeed is by working with the graphic handle... here a sample I can't get working: var d = new PdfDocument(); var p = d.AddPage(); var g = XGraphics.FromPdfPage(p); g.DrawLine(new XPen(XColor.FromArgb(0)), new XPoint(10, 10), new XPoint(100,10)); var h = g.Graphics.GetHdc(); var gg = Graphics.FromHdc(h); gg.DrawLine(new Pen(Color.FromArgb(0)), new Point(10, 20), new Point(100,20)); d.Save("test.pdf"); Can you help me to draw directly from the hdc? |
Page 1 of 1 | All times are UTC |
Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |