i cant open pdf file in angular
i have a local path and i need to open the file in a new tab
i try to do that with _blank and it not worked
thanks !
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Naimish MakwanaPosted Feb 8, 2023, 5:37 AM
If Window.Open() with _balnk not working than you can try with Iframe.
EX:
Thanks
Naimish Makwana
Marvin ReidPosted Feb 7, 2023, 8:07 PM
You can load a PDF using the DocumentFactory loadFromUri method in Angular. You can then view the pdf using a DocumentViewer object. Here is a snippet of the code which highlights this from the below example.
https://www.leadtools.com/help/sdk/tutorials/html5-js-display-files-in-the-document-viewer.html
https://www.leadtools.com/help/sdk/v22/dh/javascript/doxui/documentviewer.html
Rajanikant HawaldarPosted Jan 29, 2020, 8:23 AM