HI Team,
We are rendering PDF contains two pages one page is for type: "multipletext"
and the other page is for type: "html"
both are separate pages only. For type: "multipletext"
we need an height of 240
and for type: "html"` we required an height of
600``` dynamically.
please help us to achieve this. Pease find the code below
Codeelements: [ {
type: "multipletext",
hideNumber: true,
items,
colCount: 1,
defaultValue: formDataJson
}
]
elements: [{
type: "html",
name: "html_as_image",
html: wrapperDiv.innerHTML,
renderAs: "image",
}
]
Codelet pdfWidth = !!surveyModel && surveyModel.pdfWidth ? surveyModel.pdfWidth : 210
let pdfHeight = !!surveyModel && surveyModel.pdfHeight ? surveyModel.pdfHeight : 240; //This should be dynamic depends on the page type
let options: IDocOptions = {
fontSize: 9,
haveCommercialLicense: true,
margins: {
left: 10,
right: 10,
top: 10,
bot: 10
},
fontName: "calibri",
textFieldRenderAs: 'multiLine',
format: [pdfWidth, pdfHeight]
};
Please let us know for any clarifications.