# plugins.pdf\_output.endMetaPrintJob returns null

**URL:** <https://forum.servoy.com/t/plugins-pdf-output-endmetaprintjob-returns-null/8091>\
**Category:** Classic Servoy\
**Created:** [September 4, 2007, 9:35am UTC](https://forum.servoy.com/t/plugins-pdf-output-endmetaprintjob-returns-null/8091 "2007-09-04T09:35:36Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![patrick](https://avatars.discourse-cdn.com/v4/letter/p/b2d939/32.png) [@patrick](https://forum.servoy.com/u/patrick)\
**Post date:** [September 4, 2007, 9:35am UTC](https://forum.servoy.com/t/plugins-pdf-output-endmetaprintjob-returns-null/8091/1 "2007-09-04T09:35:36Z")

</div>

Hello,

when we use this code

```auto
var StartPdf = plugins.pdf_output.startMetaPrintJob(tempfile);
...
var thePdf = plugins.pdf_output.endMetaPrintJob();

```

the result of endMetaPrintJob() is always null, although the tempfile PDF is created and has content. Am I misunderstanding something here?

Also it seems that the PDF output of HTML stuff is not exactly what you get when we print to a printer. Especially (cell) borders are missing. Maybe somebody knows a workaround?

Thanks  
Patrick

---

<div class="post-metadata">

**Author:** ![Harjo](https://yyz2.discourse-cdn.com/flex010/user_avatar/forum.servoy.com/harjo/32/4873_2.png) [@Harjo](https://forum.servoy.com/u/Harjo)\
**Post date:** [September 4, 2007, 10:56am UTC](https://forum.servoy.com/t/plugins-pdf-output-endmetaprintjob-returns-null/8091/2 "2007-09-04T10:56:22Z")

</div>

we always do this:

```auto
plugins.pdf_output.startMetaPrintJob() 
...
var pdf = plugins.pdf_output.endMetaPrintJob()
var filename = plugins.file..createTempFile('invoice', '.pdf')
plugins.file.writeFile(filename,pdf);

```

this does not return null

---

<div class="post-metadata">

**Author:** ![patrick](https://avatars.discourse-cdn.com/v4/letter/p/b2d939/32.png) [@patrick](https://forum.servoy.com/u/patrick)\
**Post date:** [September 4, 2007, 11:28am UTC](https://forum.servoy.com/t/plugins-pdf-output-endmetaprintjob-returns-null/8091/3 "2007-09-04T11:28:13Z")

</div>

Ah, you mean as soon as I provide a file when starting the job then the endMetaPrintJob doesn’t return anything anymore? That could be, but then the sample code is wrong. Because there is suggested that you can write a file AND at the end put the pdf in a blob in one go.
