| Ken Halter 2005-03-10, 9:00 pm |
| "Trimbitas Sorin" <nekhbet(NO SPAM)@go.ro> wrote in message
news:u1i$kaaJFHA.2980@TK2MSFTNGP10.phx.gbl...
> Hello
> I'm trying to open a PDF file inside a form but it doesn't seem to work
> properly(the application stops responding)... I have registered the
> ActiveX which came with Adobe Acrobat Reader 7 and added a control to my
> form.
>
> Here is the code i used ...
> ----
> pDF1.Top = 50
> pDF1.Left = 50
> pDF1.Width = Me.Width - 250
> pDF1.Height = Me.Height - 1000
> pDF1.LoadFile(DelSlash(App.path & "\test.pdf"))
> ------
>
> Thank you
fwiw, I just dropped one on a form and pointed it to it's own help file...
This seems to work fine.
What does that "DelSlash" function do? Maybe it should look more like
pDF1.LoadFile(DelSlash(App.path) & "\test.pdf")
'==================
Option Explicit
Private Sub Form_Load()
Call AcroPDF1.LoadFile _
("C:\Program Files\Adobe\Acrobat 7.0\Help\ENU\Reader.pdf")
Me.WindowState = vbMaximized
End Sub
Private Sub Form_Resize()
AcroPDF1.Move 0, 0, Me.ScaleWidth, Me.ScaleHeight
End Sub
'==================
--
Ken Halter - MS-MVP-VB - http://www.vbsight.com
Sign up now to help keep VB support alive - http://classicvb.org/petition
Please keep all discussions in the groups..
|