PRIM_WEB.PAGE in iOS loads just the first page of a multi page PDF

This Q&A forum allows users to post and respond to "How Do I Do ....." questions. Please do not use to report (suspected) errors - you must use your regional help desk for this. The information contained in this forum has not been validated by LANSA and, as such, LANSA cannot guarantee the accuracy of the information.
Post Reply
UrriahAguilera
Posts: 9
Joined: Wed Feb 08, 2017 3:20 pm

PRIM_WEB.PAGE in iOS loads just the first page of a multi page PDF

Post by UrriahAguilera »

i made a very simple webpage (code found below) that loads a book in a PRIM_WEB.Page class and ran it in multiple devices. Running it on desktop/android devices, it loads the PDF in the PRIM_WEB.Page class and shows navigation buttons. When i run the same webpage in iOS it seems like it only loads the very first page without the navigation buttons. is there a way i can show said navigation buttons when running this webpage in iOS?

the sample code below loads a copy of Homer's The Odyssey. You can replace it with another PDF but iOS will only show the very first page with no way of getting to the next.

Code: Select all

Begin_Com Role(*EXTENDS #PRIM_WEB) Theme(#SYS_THEME<MaterialDesignBlue>) Layoutmanager(#Layout1)

Define_Com Class(#PRIM_TBLO) Name(#Layout1)
Define_Com Class(#PRIM_TBLO.Row) Name(#Layout1Row1) Displayposition(1) Parent(#Layout1)
Define_Com Class(#PRIM_TBLO.Column) Name(#Layout1Column1) Displayposition(1) Parent(#Layout1)
Define_Com Class(#PRIM_TBLO.Item) Name(#Layout1Item1) Alignment(TopCenter) Column(#Layout1Column1) Manage(#Page1) Parent(#Layout1) Row(#Layout1Row1)


Define_Com Class(#PRIM_WEB.Page) Name(#Page1) Description('Web Page') Displayposition(1) Height(390) Parent(#COM_OWNER) Tabposition(1) Tabstop(False) Width(1190) Top(5) Left(5)

Evtroutine Handling(#Com_owner.Initialize)
#page1.Source := 'https://www.stmarys-ca.edu/sites/default/files/attachments/files/The_Odyssey.pdf'
Endroutine
End_Com
User avatar
Dino
Posts: 472
Joined: Fri Jul 19, 2019 7:49 am
Location: Robbinsville, NC
Contact:

Re: PRIM_WEB.PAGE in iOS loads just the first page of a multi page PDF

Post by Dino »

This will work for both devices:

Code: Select all

#page1.Source := 'https://www.stmarys-ca.edu/sites/default/files/attachments/files/The_Odyssey.pdf'
#sys_web.Navigate Url(#Page1.Source) Target(New)
you need to "download" it to be able to open it fully.

or just this for apple:

Code: Select all

#sys_web.Navigate Url('https://www.stmarys-ca.edu/sites/default/files/attachments/files/The_Odyssey.pdf') Target(New)
Post Reply