PB4.2 beta 2 - WebGadget and the new. Acrobat Reader[solved]

Windows specific forum
User avatar
fsw
Addict
Addict
Posts: 1603
Joined: Tue Apr 29, 2003 9:18 pm
Location: North by Northwest

PB4.2 beta 2 - WebGadget and the new. Acrobat Reader[solved]

Post by fsw »

This is just a "heads on" for you guys to let you know that since I updated to the newest "Acrobat Reader 8.1.2" this:

Code: Select all

WebGadget(#PDF_Gadget_2, 6, 6, WindowWidth(#PDF_Window), WindowHeight(#PDF_Window), "")
SetGadgetText(#PDF_Gadget_2, PDF_FILE_SHOW$ + ".pdf")
doesn't display the pdf file inside the WebGadget anymore, but in a new opened Acrobat Reader Window (crappy Acrobat Reader plug-in I suppose).

I know this is for sure a Acrobat Reader issue, but maybe you guys can adapt your code accordingly to the new Acrobat Reader plug-in.

Thanks
fsw
ABBKlaus
Addict
Addict
Posts: 1143
Joined: Sat Apr 10, 2004 1:20 pm
Location: Germany

Post by ABBKlaus »

no problems here on my system using this code :

Code: Select all

If OpenWindow(0, 0, 0, 600, 300, "WebGadget", #PB_Window_SystemMenu | #PB_Window_ScreenCentered) And CreateGadgetList(WindowID(0))
  WebGadget(0, 10, 10, 580, 280, "")
  ; Note: if you want to use a local file, change last parameter to "file://" + path + filename
  Time=ElapsedMilliseconds()
  Repeat
    Event = WaitWindowEvent(250)
    If Event=0
      Timediff=ElapsedMilliseconds()-Time
      If Timediff>5000
        Time=ElapsedMilliseconds()
        Show+1
        Select Show
          Case 1
            SetGadgetText(0,"http://www.purebasicpower.de/downloads/PDFBarcodeSample.pdf")
            Debug "1"
          Case 2
            SetGadgetText(0,"file://C:\Downloads\Schnellreferenzkarte.pdf")
            Debug "2"
          Case 3
            SetGadgetText(0,"http://www.purebasic.com")
            Debug "3"
          Default
            Show=0
            Debug "Reset"
        EndSelect
      EndIf
    EndIf
  Until Event = #PB_Event_CloseWindow
EndIf
Windows Vista Home Premium (32 Bit) / Adobe Reader 8 Version 8.1.2
rsts
Addict
Addict
Posts: 2736
Joined: Wed Aug 24, 2005 8:39 am
Location: Southwest OH - USA

Post by rsts »

Could be that the acrobat install has associated all pdf activities with acrobat or something along those lines.

cheers
User avatar
fsw
Addict
Addict
Posts: 1603
Joined: Tue Apr 29, 2003 9:18 pm
Location: North by Northwest

Post by fsw »

Thank you both for your replies.

This:

Code: Select all

SetGadgetText(0,"http://www.purebasicpower.de/downloads/PDFBarcodeSample.pdf")
shows the pdf file in a separate acrobat reader window.
(and so does every local pdf file)

Regarding the association of pdf files:
the webgadget tries to load the pdf file directly with the acrobat plug-in.
I suppose this fails and falls back into a normal acrobat reader window.

BTW: XPproSP2 with all the updates is used.
ABBKlaus
Addict
Addict
Posts: 1143
Joined: Sat Apr 10, 2004 1:20 pm
Location: Germany

Post by ABBKlaus »

fsw wrote:This:

Code: Select all

SetGadgetText(0,"http://www.purebasicpower.de/downloads/PDFBarcodeSample.pdf")
shows the pdf file in a separate acrobat reader window.
not here :
Image

PS : If you configured Adobe Reader (Internet/Display PDF in browser=not checked) you get that result :wink:
User avatar
fsw
Addict
Addict
Posts: 1603
Joined: Tue Apr 29, 2003 9:18 pm
Location: North by Northwest

Post by fsw »

ABBKlaus wrote:PS : If you configured Adobe Reader (Internet/Display PDF in browser=not checked) you get that result :wink:
Klaus,
Acrobat Reader has under:
  • Edit -> Preferences -> Internet
some options for the Web Browser.

The option:
  • Display PDF in browser
was checked, but it didn't work as expected...

After seeing that this option is checked correctly I switched this option off and let the Reader save this setting.
Testing this revealed that it showed the pdf file in an extra Reader window.

Now I switched it back on and saved this setting.
Testing this revealed that it showed the pdf file in the WebGadget as it should. :D

Conclusion:
the update of Acrobat Reader didn't care about this setting, but after checking it off and on again forced Acrobat to "get it". :shock:

Thanks for your help.

@admin
please move this topic to a place you like, as it seems it's an acrobat Reader issue not PureBasic's.
Post Reply