<p>Hi David,</p>
<p>It looks like the only challenge you're dealing with is configuring workflow to extract the page count number from the database so I'll just address that. Once you've created your global variable for holding the page count, you go into an Assign Data step and assign the global variable using an entry type of External Data. When you open the panel to configure the external data lookup, under database configuration you pick "Content", under table you pick the name of your file cabinet, and then over in the column drop-down on the right you'll see a most excellent list of system fields, including your most coveted "DWTOTALPAGES". Fill out the "WHERE clause" with your criteria so the lookup finds your document (using DWDOCID = 'GV_DocId' is the usual way, where GV_DocId is a global variable you've already populated with your document's DOCID) and you should be all set.</p>