You can either save data to DBase and read back or populate
direct.
Design a PDF form with fields using Adobe Acrobat
professional, assign names to all fields, then populate same from
CF as follows:
DO YOUR DATABASE QUERY. Make sure you are careful to follow
field defenition and variable tags << /V(Variable) /T(Field
Name) >>
This provides very robust method for populating fields in PDF
form. If it hangs just remove the <CFSETTING> and
<CFCONTENT> lines to check if CF is throwing an error, as PDF
will just hang.
Ted Daniels
<body>
<CFOUTPUT>
<CFSETTING enablecfoutputonly="Yes"
showdebugoutput="yes">
<CFCONTENT Type="application/vnd.fdf">
%FDF-1.2
1 0 obj
<<
/FDF
<<
/Fields
[
<< /V (<CFIF #GetAccident.Fatal# is
1>x</CFIF>)/T (Fatal)>>
<< /V (<CFIF #GetAccident.CMV# is
1>x</CFIF>)/T (CMV)>>
<< /V (<CFIF #GetAccident.SchoolBus# is
1>x</CFIF>)/T (SchoolBus)>>
<< /V (<CFIF #GetAccident.RailRoad# is
1>x</CFIF>)/T (RailRoad)>>
<< /V (<CFIF #GetAccident.MAB# is
1>x</CFIF>)/T (MAB)>>
<< /V (<CFIF #GetAccident.HitandRun# is
1>x</CFIF>)/T (HitAndRun)>>
<< /V (<CFIF #GetAccident.Supplement# is
1>x</CFIF>)/T (Supplement)>>
<< /V (#GetAccident.CountyName#)/T
(CountyName)>>
<< /V (#GetAccident.CityName#)/T (CityName)>>
<< /V (#GetAccident.DistanceCity#)/T
(DistanceCity)>>
<< /V (<CFIF #GetAccident.DirectionCity# is
'North'>x</CFIF>)/T (DirectionCity_N)>>
]
/F (PathName/PDF_FILE.pdf)
>>
>>
endobj
trailer
<</Root 1 0 R>>
%%EOF
</CFOUTPUT>
</body>