Custom print headers and footers

I’m trying to make a print-friendly page to display a technical report. I’ve tried FormStack Documents (formerly WebMerge), but with only limited success so far. Because I want the report to include things like photos, rich text, maps, and charts, it seems my best option is to customize Knack rather than integrate it with another platform.

The main thing holding me back from this is that the report needs to contain headers and footers with certain information.

I’ve created a page and layed out my elements as I want them. I’ve inserted page breaks where required using rich text block with some code I picked up in another post.

Now I’m trying to include custom headers and footers. The header should look something like:

{Report Name}

And the footer:

Static Text [then tab stop, right align with right margin]

The challenges, as I see them (though I’m not a developer) are:

  1. {Report Name} would need to be identified from the object that the first view on the page draws from.
  2. could be difficult if the size of the report content changes, though a more simple approach (possibly) could be to count the page breaks, but as I say, I’m no developer.

I’ve found some information about things like Prince XML and wktopdf, but I really don’t know where to start.

Does this sound at all feasible? Can anyone point me in the right direction?

Thanks

Chris

It seems some of my earlier text got cut off. The footer should read:

Static Text [then tab stop, right align with right margin] (pagenumber) of (numberofpages)

Additionally, numbered bullet two should read:

  1. Inserting the number of pages could be difficult if the size of the report content changes, though a more simple approach (possibly) could be to count the page breaks, but as I say, I’m no developer.

Did you ever figure out how to get page numbers? I’m running into some of the exact issues you have. Sometimes the page break inserts an almost empty page and even though it says there are more pages without page numbers this could get lost if there are several pages or printed the order would be a big ??

Hi De_Anna

No, unfortunately, I haven’t been able to resolve this. My client decided that the particular project was a low priority so I’ve moved on to other work instead.

If you have budget for this, you could reach out to the Knack Expert Network to see if someone can write you the code you need to make this work.

While I think Knack plus custom code would be a good solution for my project, an alternative is to drop Knack and get staff to enter their results directly into Docupilot. Alternatively, I could integrate Knack and Docupilot, but I don’t think either of these alternatives would cope with rendering charts or performing other numerical calculations.

It’s a shame it’s not as simple as it sounds.

Let me know if you have any luck!

Cheers

Chris