Why I'm unable to create PDF from a form?