01.
{
02.
string
file =
"D:/test.pdf"
;
03.
string
image =
"D:\\test.png"
;
04.
05.
try
06.
{
07.
GflAx.GflAxClass g =
new
GflAx.GflAxClass();
08.
g.EpsDpi = 150;
09.
g.Page = 1;
10.
g.LoadBitmap(file);
11.
g.SaveFormat = GflAx.AX_SaveFormats.AX_PNG;
12.
g.SaveBitmap(image);
13.
MessageBox.Show(
this
,
"PDF to PNG conversion ended"
);
14.
}
15.
catch
(Exception ex) {
16.
MessageBox.Show(
this
,
"GflAx error: "
+ ex.Message);
17.
}
18.
}