| View previous topic :: View next topic |
| Author |
Message |
saibejugam General User


Joined: 21 Jan 2005 Posts: 7
|
Posted: Fri Jan 21, 2005 3:42 am Post subject: Page size pblm when converting HTML to PDF |
|
|
hi all,
firslty,sorry for posting this as a sticky previously... it was unknowingly done
my pblm:
i am able to convert an html page to pdf using filter "writer_web_pdf_export"
but the page size of the pdf is shrinked to the contents i mean if an html page has a paragraph with 3 lines n when i converted it into a pdf then the size of the page is literally 7.18 X 2.19in as shown in acrobat reader
following is my code snippet:
XModel xmodel = (XModel)UnoRuntime.queryInterface(com.sun.star.frame.XModel.class, xcomponent);
XFrame xframe = xmodel.getCurrentController().getFrame();
xframe.activate();
XStorable xstorable = (XStorable)UnoRuntime.queryInterface (com.sun.star.frame.XStorable.class, xcomponent);
PropertyValue[] filterProps = new PropertyValue[2];
filterProps[0] = new PropertyValue();
filterProps[0].Name = "CompressMode";
filterProps[0].Value = "1";
filterProps[1] = new PropertyValue();
filterProps[1].Name = "PageRange";
filterProps[1].Value = "1";
PropertyValue apropertyvalue[] = new PropertyValue[2];
apropertyvalue[0] = new PropertyValue();
apropertyvalue[0].Name = "FilterName";
apropertyvalue[0].Value ="writer_web_pdf_Export;
apropertyvalue[1] = new PropertyValue();
apropertyvalue[1].Name = "FilterData";
apropertyvalue[1].Value = filterProps;
xstorable.storeToURL(lStrFilePath, apropertyvalue);// here lStrFilePath is the pdf file path
please somebody help me out in this.. |
|
| Back to top |
|
 |
DannyB Moderator


Joined: 02 Apr 2003 Posts: 3991 Location: Lawrence, Kansas, USA
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|