You need to sign in to do that
Don't have an account?
liron169
Identify empty PDF
Hi.
I'm using function getContent(), to get blob of PDF page.
There are cases where the PDF is empty (blank page), and it's fine. The question how can I detect it.
-I cannot inspect the blob ,as the characters have no meaning....
-In the controller of the PDFpage I have such indication, but I cannot access it in the caller process.
Any suggestions?
PageReference page = new PageReference('/apex/PDFpage...');
blob bodyAttach=page.getContent();
I'm using function getContent(), to get blob of PDF page.
There are cases where the PDF is empty (blank page), and it's fine. The question how can I detect it.
-I cannot inspect the blob ,as the characters have no meaning....
-In the controller of the PDFpage I have such indication, but I cannot access it in the caller process.
Any suggestions?
PageReference page = new PageReference('/apex/PDFpage...');
blob bodyAttach=page.getContent();
All Answers
The issue is how the caller (code which open this page with getContent), can get response from the page, which inform it that pdf will be empty.