Stupid ColdFusion error message!!!

So, there I was sticking a wee <cfdocument> tag in my code when I got a strange error...

The document has no pages.

Eh? Said I. So I tried a simple example...

<cfdocument format="pdf">
Cows go Moo...
</cfdocument>

Same error...

And then I had a thought ... could the watermark.png file be missing? (See this post)

And sure enough, that was the problem.

When the watermark.png file is missing from the Developer Edition you'll get an error. When the format is set to Flashpaper it tells you the watermark.png file is missing... awesome, it tells you exactly what's wrong.

When set to PDF however, it tells you that the document has no pages.

Stupid! Stupid! Stupid!

The number of obscure and misleading error messages in ColdFusion does my head in!!!

Related Blog Entries

Comments

Damon Cooper's Gravatar Sorry about the blank pages, but the essence is: no watermark file (or the wrong one) and we bail on creating your doc in Developer Edition. Hey, we gotta make a living somehow :)

Damon
# Posted By Damon Cooper | 21/09/06 17:37

Andy Allan's Gravatar Hey Damon,

No complaints about the watermark in the developer edition ... the devs here all run that locally, and then we have fully licensed versions in staging and production. So we cough up the dosh :)

The post was really about the silly, and incorrect error message.
# Posted By Andy Allan | 21/09/06 17:42

Rupesh Kumar's Gravatar I knew some one will face this but never heard about it on forum or from support. I noticed this problem sometime back and fixed it in the scorpio. Actually the error message was being thrown properly but in case of pdf, this was not being propagated and it resulted into another exception. The same error gets propagated when the format is flashpaper.
# Posted By Rupesh Kumar | 21/09/06 21:02

Gary's Gravatar Here is a great odd error message ...
"5" on line 39 ....
while creating a new object.

5 is very helpful (CF8)
# Posted By Gary | 03/07/08 12:20

Scotch on the Rocks 2008