Subscribe for automatic updates: RSS icon RSS

Login icon Sign in for full access | Help icon Help
Advanced search

Pages: [1]
  Reply  |  Print  
Author Topic: GWC view PDF file  (Read 12460 times)
Jeff W.
Posts: 31


« on: November 11, 2010, 12:10:57 am »

When viewing a PDF using GWC front-end, the provided app "gviewpdf" displays a newly created PDF file using a Menu (example attached).  Is there another way to do this without the Menu?  I can't find a frontcall used by GWC to open a PDF directly, but the Menu solution is awkward.


* GWCPDF.PNG (6.65 KB, 227x227 - viewed 2195 times.)
Terry H.
Posts: 1


« Reply #1 on: November 11, 2010, 03:37:30 pm »

If you can copy the server-side pdf to a directory under the GAS DOCROOT, you can open it as a relative url using frontcall launchurl.

#-- pseudo-code
if (os.Path.copy(my_pdf, "%FGLASDIR%\\web\\my_dir\\"||my_pdf)) then
   let pdf_url = "/my_dir/my_pdf"
   call ui.Interface.frontCall("standard", "launchurl", [pdf_url], [])
end if

In as.xcf, see also:
<RESOURCE Id="res.path.docroot" Source="INTERNAL">$(res.path.as)/web</RESOURCE>
...
<DOCUMENT_ROOT>$(res.path.docroot)</DOCUMENT_ROOT>

Or, something like that!
HTH, Terry
Pages: [1]
  Reply  |  Print  
 
Jump to:  

Powered by SMF 1.1.21 | SMF © 2015, Simple Machines