Back to workVue + FileMaker

Dynamic PDF Printouts

Invoices, proposals and inspection sheets rebuilt in Vue, so printouts grow to fit their content and break cleanly across pages instead of being cut off by fixed FileMaker layouts.

VueFileMakerPDF Generation
Overview

An automatic door inspection and service company runs its jobs, billing and inspections in FileMaker, and every one of them ends in a printed PDF. I built a Nuxt app that takes the record from FileMaker, lays it out as a Vue page that sizes itself to the data, and prints it to PDF with headless Chrome before handing the file back to FileMaker.

01

Problem

FileMaker layouts are built from fixed-size objects that can’t grow with their content, and they don’t split long content across pages well. A long scope of work or a long list of line items got cut off or broke awkwardly across pages, so printouts had to be checked and fixed by hand.

02

Approach

Rebuilt each printout as a Vue page fed with JSON from FileMaker. Every section sizes itself to its content, so text wraps and tables grow as long as they need to. Before printing, the page measures each section against the height of the paper the form prints on and moves any section that would straddle a page break to the next page, while headers, totals and signature blocks are kept whole. Puppeteer then renders the page at that form’s paper size, orientation and margins.

03

Result

Invoices, proposals and purchase orders now print with every line item and the full text of every note, however long. Technicians fill in and sign the inspection sheets on site, and each one prints as a landscape Letter sheet laid out like the paper form.

Screens

My role

I built the app on my own, from the Vue printouts and the page-splitting logic to the PDF server and the scripts that pass data between the app and FileMaker.

The forms

  • Invoice, proposal and purchase order: generated straight from FileMaker Pro records. Line items, labor, scope of work, notes and totals all size to their content, and several invoices can be printed at once and merged into a single PDF.
  • AAADM inspection sheets: five landscape sheets for swinging, sliding, folding, low energy and double egress doors. Technicians fill them in on tablets, with click-to-cycle compliance marks, comments and signature pads.
  • Service ticket: a portrait Letter ticket covering the customer, equipment, work performed, materials, technicians and sign-off.

How the layout adapts

  • Content sets the size: sections are laid out with flexbox and tables instead of fixed boxes, so a one-line note and a full page of scope take exactly the room they need.
  • Page splitting: each form knows its paper height, A4 or Letter, portrait or landscape. A pass after rendering finds any section that would cross a page boundary and starts it on the next page instead, and smaller blocks like the header, customer details and footer are marked so they never split.
  • Screen and paper from one page: the inspection sheets switch to a stacked, touch-friendly layout on a phone and render as the full printed sheet on a wide screen or in the PDF, so technicians and the PDF server use the same page.
  • Reliable output on the server: compliance marks are drawn as SVG instead of Unicode symbols, which printed fine on a Mac but came out blank from the Linux PDF server, and printing waits for every signature image to decode so signature lines never come out empty.

Getting the PDF back to FileMaker

  • FileMaker Pro: the record arrives as JSON over the web viewer’s JavaScript bridge, and the finished PDF goes back to a FileMaker script that files it against the record.
  • WebDirect: the bridge doesn’t exist there, so the inspection sheets save through a FileMaker Data API proxy that only accepts requests carrying a launch token signed by FileMaker, and the PDF is filed against the job.
  • No lost work: answers autosave as the technician works, and a form is only cleared once FileMaker confirms it has the PDF.

These printouts later became the reference for the Custom Form Builder, which lets office staff design new inspection sheets without code.


Dynamic PDF Printouts Discuss a similar project →

© 2026 Grant Gonzalez

Built with FileMaker & the web in mind