I started playing more with cfdocument. The below code fit a div with a 1px
border exactly onto a 8.5x11 document. You move it 1px in any direction and it
gets funky... there is definitely some translation when going from HTML to PDF
when using CFDocument.
<cfdocument format="pdf" pagetype="letter" margintop="0" marginbottom="0"
marginleft="0" marginright="0">
<div style="border: 1px solid #000000;
width: 613px;
height: 795.5px;
position: absolute;">
</div>
</cfdocument>
-----Original Message-----
From: Arthur.Frey [mailto:[EMAIL PROTECTED]
Sent: Tuesday, July 31, 2007 1:43 PM
To: CF-Talk
Subject: CFDocument Help
I am trying to create a 2 page document with a custom page size (17x11
inches). The basics of the document are a table that should fill 100% of
the document in two columns.
Example:
Create a new cf page and paste the following code:
<cfdocument name="MyPDF" filename="MyPDF.pdf" format="PDF"
pagetype="custom" pageheight="11" pagewidth="17" margintop="0"
marginbottom="0" marginright="0" marginleft="0" orientation="portrait"
unit="in" backgroundvisible="yes" overwrite="yes" fontembed="no">
<cfdocumentsection margintop="0" marginbottom="0" marginright="0"
marginleft="0">
<table width="1650" border="0" cellpadding="0" cellspacing="0"
bgcolor="#000000">
<tr>
<td width="825" height="1050" style="color:#FFFFFF">page 1, column 1</td>
<td width="825" height="1050" style="color:#FFFFFF">page 1, column 2</td>
</tr>
</table>
</cfdocumentsection>
<cfdocumentsection margintop="0" marginbottom="0" marginright="0"
marginleft="0">
<table width="1650" border="0" cellpadding="0" cellspacing="0"
bgcolor="#000000">
<tr>
<td width="825" height="1050" style="color:#FFFFFF">page 2, column 1</td>
<td width="825" height="1050" style="color:#FFFFFF">page 2, column 2</td>
</tr>
</table>
</cfdocumentsection>
</cfdocument>
<a href="MyPDF.pdf" target="_blank">MyPDF.pdf</a>
When you click on the link you will see a pdf generated that is 2 pages
long. I need one page. I am going to be filling these two columns with
images and text generated from a database, but this basic framework is
the key.
I have no idea how to build this so it fills in 100% of the page and not
overflow onto an extra page. Any help would be greatly appreciated. Even
if you can help me learn the height and width of the anticipated PDF at
17x11inches I would be thrilled.
I would be happy to send you the origional pdf is that would help anything.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Download the latest ColdFusion 8 utilities including Report Builder,
plug-ins for Eclipse and Dreamweaver updates.
http;//www.adobe.com/cfusion/entitlement/index.cfm?e=labs%5adobecf8%5Fbeta
Archive:
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:284969
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4