-
Unanswered: Printing a PDF file loaded to the ContentPanel -
Unanswered: Printing a PDF file loaded to the ContentPanel -
I loaded PDF file to the ContentPanel using setUrl method. I want to print the PDF by using the
following native function.
ContentPanel panel = new ContentPanel();
Frame frame = panel.setUrl("/url/of/file.pdf');
frame.setId("printId");
The native function is this
function printTrigger(elementId) {
var getMyFrame = document.getElementById(elementId);
getMyFrame.focus();
getMyFrame.contentWindow.print();
}
// This suggestion is from http://stackoverflow.com/questions/6...ith-javascript
I always get null frame. Though the PDF is displaying properly in the ContentPanel.
I debugged the frame.getElement().getId() which is also correct.
Please help in pointing the error.
thanks!
Sencha is used by over two million developers. Join the community, wherever you’d like that community to be
or Join Us