3 Replies Latest reply on Dec 9, 2017 5:04 AM by lbourelly-2 RSS
    gfiore Explorer

    PDF View into experience

    Hello everyone,

    How do i view a pdf file into experience with a mobile android?

    I tried to use this procedure

    $scope.popup = function() {

        var options = {

          cssClass: 'popup-custom',

          title: "PDF!",

          template: "<iframe src='app/resources/Uploaded/prova.pdf' frameborder='0' style='width: 100%; height: 600px'></iframe>",

          okText: "Close"


        var popup = $ionicPopup.alert(options);

        popup.then(function(res) {

          //do something




    In preview the pdf file is visible, but with the thingworx viewer the screen turns out to be white.


    also tried using a hyperlink widget, but if I use a file that is not on the Resources it works,

    if instead I use a file into resource repository  source 'app / resources / Uploaded / NomeFile.pdf' on

    thingworx view the upload remains blocked on loading.




      • Re: PDF View into experience
        rolandr Explorer

        Hi Giuseppe,

        I did a quick test in the preview and it seems to occur only if you call it one or two time and then it was all later calls are working fine.07-12-2017 17-06-56.jpg

        07-12-2017 17-10-51.jpg

        07-12-2017 17-11-40.jpg

        So this is the behavior in preview but testing in thingworx view the popup windows is white and does not display the pdf

        So that seem to be some issue ... need further checks...

          • Re: PDF View into experience
            rolandr Explorer

            Hi Giuseppe,


            I asked the development and received the following answer:


            I should note that the web view on Android (i.e. Chrome for Android) has no built-in PDF viewing capbility.  If you want to view a PDF there you either:

            1. Use SVG instead (converting as necessary) or
            2. Allow the PDF to go to an external viewer

            Note that there is no guarantee that the device in question will have a PDF viewer, though most do as Google Drive is one such viewer.


            I hope is this helpful!

          • Re: PDF View into experience
            lbourelly-2 Newbie

            Hello Giuseppe,

               I'm doing that in a different way for experience's performance reasons, you can store your PDF file in Thingworx by deploying an Extension like "File Repository Home Mashup" available in the market place on your Experience Server, once your file uploded you can execute a service to get the PDF file's URL,  and use the 2D URL Widget in Studio to give an access to your document.

            I hope this can help you.