I have answered most of my own questions. setHTMLTempalte() works when I set the area height manually (setAreaHeight(150)) and do not set the HTML width (setHTMLWidth(950)) and do not use width=”100%” in the
tag. But I cannot use setAreaHeight(-1) to allow pd4ml to calculate appropriate height. The top of the header is cut off.
Any suggestions on how to auto-adjust header and footer heights? In my applications the headers will be dynamically generated so it would be nice to have a way to expand and shrink the height as needed rather than set a fixed height.