Hello,
We have a cloud based application with angular 6(client) and asp.net (back end).
Currently, we are printing various accounting reports using crystal report. Actually, what we are doing like we take the output of crystal report and converting it to base64 string and we are returing this string to front end that is angular. Then we are printing this output string into a new tab in chrome. Code is as follows.
- const pdfWindow = window.open("");
- pdfWindow.document.write("<html<head><title>Discharge Summarytitle><style>body{margin: 0px;}iframe{border-width: 0px;}style>head>");
- pdfWindow.document.write("<body><embed width='100%' height='100%' src='data:application/pdf;base64, " +
- encodeURI(data) + "#toolbar=0&navpanes=0&scrollbar=0'>embed>body>html>");
Thank you in advance.
Replies
Know the answer? Post it — somebody with the same question will find it here.