Skip to main content
Participant
November 30, 2009
Question

CFDocument and trouble converting to pdf

  • November 30, 2009
  • 3 replies
  • 1325 views

Hello,

I'm simply trying to convert a word doc to .pdf using CF9.  But when I try it, I get the following error...

500 - Internal server error.

There is a problem with the resource you are looking for, and it cannot be displayed.

Also, coldfusion services seem to go down for a few moments (i can't render any coldfusion pages on the server) and then after a few moments the CF services are back.

What could be causing this???

Here is the simple code I am using...

<cfdocument format="pdf" srcfile="\\srvTestServer\wwwroot\officetopdf\worddocs\Infograms Inventory.doc" filename="\\srvTestServer\wwwroot\officetopdf\pdfdocs\test.pdf"></cfdocument>

Now if I take out the srcfile section of the tag and hard code text into the cfdocument, it works with no problem???

example

<cfdocument format="pdf" filename="\\srvTestServer\wwwroot\officetopdf\pdfdocs\test.pdf">This is a test message for my pdf file</cfdocument>

I hope someone can shead some light on this?

Thanks In Advance,

Cedric Gaines

    This topic has been closed for replies.

    3 replies

    Inspiring
    December 5, 2009

    Hi,

    <cfdocument format="pdf" srcfile="\\srvTestServer\wwwroot\officetopdf\worddocs\Infograms Inventory.doc" filename="\\srvTestServer\wwwroot\officetopdf\pdfdocs\test.pdf"></cfdocument>

    Is that because of the whitespace that you placed between the "Infograms" and "Inventory"?.

    Inspiring
    December 4, 2009

    Is OpenOffice installed on your machine?  I believe this is a requirement to work with Word files in CF9.

    Office file interoperability

    http://help.adobe.com/en_US/ColdFusion/9.0/Developing/WS56EA2935-FBD2-4089-8402-FDDA2BAF55FB.html

    Configuring OpenOffice

    http://help.adobe.com/en_US/ColdFusion/9.0/Installing/WS899EE911-747B-45cf-8550-DC9123823364.html

    Inspiring
    November 30, 2009

    Try these tests and report back pls:

    1) create a very simple "hello world" sort of .doc file, and try the process with that instead;

    2) if it still doesn't work with the simple .doc file via the UNC path, try it on a local path;

    3) also try with a file that doesn't have a space in its file name.

    --

    Adam

    cis4lifeAuthor
    Participant
    November 30, 2009

    Still no go,

    I am getting the same error and same behavior?  I have created a simple .doc file with "Hello World" in it and have it as test.doc and still get the same error.  Do I need to configure anything special on the Coldfusion end to get this to work?

    Cedric