Stemon63 Posted April 5, 2017 Share Posted April 5, 2017 Hi Farshad, TuniPDFFrame is a good new (like other good recent additions). But, how to show local server files or pdf files in server subdirs? It seems that PdfUrl require only Http addresses....I need to load C:\archive\pdfxxx.pdf or simila, for example. Thanks in advance! Stefano Quote Link to comment Share on other sites More sharing options...
Administrators Farshad Mohajeri Posted April 6, 2017 Administrators Share Posted April 6, 2017 You can put all your PDFs under files folder or sub folders under files folder. Files in other locations can not be accessed directly by uniGUI server. Quote Link to comment Share on other sites More sharing options...
Stemon63 Posted April 6, 2017 Author Share Posted April 6, 2017 Ok Farshad, thank you 1 Quote Link to comment Share on other sites More sharing options...
jahlxx Posted April 6, 2017 Share Posted April 6, 2017 Hi. I try to open a pdf file located in files folder, but can't open. error: PDF.js v1.5.188 (build: 0e2d50f)Message: Unexpected server response (401) while retrieving PDF "http://localhost:8077/2017_4_6_692898.pdf". any idea? Quote Link to comment Share on other sites More sharing options...
Administrators Farshad Mohajeri Posted April 6, 2017 Administrators Share Posted April 6, 2017 You should add uniServerModule.FilesFolderURL to name of PDF. Quote Link to comment Share on other sites More sharing options...
jahlxx Posted April 6, 2017 Share Posted April 6, 2017 ok. thanks. it works for me, in standalone server, in my computer. but in isapi dll, in my case, uniServerModule.FilesFolderURL, links to apache home directory (C:/Program Files/Apache Software Foundation/Apache2.2/) why? thanks. Quote Link to comment Share on other sites More sharing options...
Administrators Farshad Mohajeri Posted April 6, 2017 Administrators Share Posted April 6, 2017 Hi, Are you sure it is: UniServerModule.FilesFolderURL This property will never return a local path. Quote Link to comment Share on other sites More sharing options...
jahlxx Posted April 6, 2017 Share Posted April 6, 2017 yes. I create the pdf in filesfolderurl and are created in apache foder Quote Link to comment Share on other sites More sharing options...
Administrators Farshad Mohajeri Posted April 6, 2017 Administrators Share Posted April 6, 2017 I'm not sure if I understand correctly. Can you please post your code here. Thx Quote Link to comment Share on other sites More sharing options...
jahlxx Posted April 6, 2017 Share Posted April 6, 2017 ok. the only way to do it, I've been doing some test with differents combinatios is: generate the pdf like this: xreport := 'test.pdf'; rep.prepare; rep.ExportToFilter(tqrPDFDocumentfiltER.Create(UniServerModule.StartPath + 'files\tmp\' + xreport)); Once is generated, show the pdf in a unipdfframe UniPDFFrame1.pdfurl := uniServerModule.FilesFolderURL + 'tmp\' + xreport; I think something here is wrong, but works for me. Is correct? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.