Serving Word - PowerPoint PPT Presentation

About This Presentation
Title:

Serving Word

Description:

September 18, 2002. Samuel R. Neff. Serving Word. Serving Word. Using HTML, XML, and CSS to ... September 18, 2002. Samuel R. Neff. Serving Word. Labels. margin: ... – PowerPoint PPT presentation

Number of Views:73
Avg rating:3.0/5.0
Slides: 18
Provided by: cfu2
Category:
Tags: sept | serving | word

less

Transcript and Presenter's Notes

Title: Serving Word


1
Serving Word
  • Using HTML, XML, and CSS to
  • Dynamically Generate Word Documents
  • Samuel R. Neff
  • B-Line Express

2
Agenda
  • Automation
  • Document Properties
  • HTML, XML, CSS
  • Formatting
  • Labels
  • Columns
  • Headers, Footers
  • Images
  • Alternatives

3
Automation
  • Control one application from another
  • Use COM object Word.Application
  • Complete flexibility and power
  • Limitations
  • Unattended execution
  • Slow
  • CF COM Support (all versions)

4
Document Properties
  • Small quantities of data
  • Very fast and easy to use
  • Safe for servers
  • Limitations
  • CF COM Support (all versions)
  • Java version incomplete (Apache POI)

5
HTML, XML, CSS
  • Familiar
  • Fast
  • Flexible

6
Hello Word
Example helloword.cfm
7
Basic Formatting
  • Sections
  • Pages
  • Margins
  • _at_page Section1
  • size8.5in 11.0in
  • margin1.0in 1.25in 1.0in 1.25in
  • div.Section1
  • pageSection1

Example letter01.cfm
8
Paragraph Formatting
Example letter02.cfm
9
Labels
Example labels01.cfm
10
Advanced Labels
  • Different sizes and layouts
  • Page Margin
  • Row Height
  • Paragraph Margins
  • Number of Columns
  • Spacers
  • Reuse code
  • Despite varying content
  • ColdFusion Components
  • Not all labels can be generated

Examples labels02.cfm, labels03.cfm,
WordLabelGenerator.cfc
11
Columns
Example columns01.cfm
12
Multi-File Documents
Examples MultipartMIME_Example.htm,
MultipartMIME.cfc
13
Headers Footers
Example columns02.cfm
14
Images
  • Use standard ltimggt tag
  • Include image in the file list
  • Include image in Multipart MIME message
  • Component automatically encodes as Base64

Example columns03.cfm
15
Resources
  • Save as Web Page
  • Microsoft Office HTML and XML Reference
  • http//msdn.microsoft.com/library/default.asp?url
    /library/en-us/dnoffxml/html/ofxml2k.asp
  • RFCs 2045 and 2046
  • http//www.ietf.org/rfc/rfc2045.txt
  • http//www.ietf.org/rfc/rfc2046.txt

16
Conclusions
  • HTML/XML/CSS Faster and more stable than COM
  • Can be used for most dynamic Word applications
  • Builds upon existing developers' skill set

17
Questions
  • sam_at_blinex.com
Write a Comment
User Comments (0)
About PowerShow.com