Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Aug 2009
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Open PDF in VB6 help!!!!!!!

    Hi, I need to open a PDF from an install CD when the “installation instruction” box is clicked. I have everything programmed except this.

    I am having trouble getting Adobe reader to open the file on the CD. Also I want it to use any version of reader that the person may have installed on the local drive. But install reader 9 if no version is detected.


    Can this be done? if so anyone have some code to do it???

    Thanks

    Ted

  • #2
    Rockstar Coder
    Join Date
    Jun 2002
    Location
    USA
    Posts
    9,074
    Thanks
    1
    Thanked 328 Times in 324 Posts
    You can do it with the ShellExecute API call in Windows. http://www.vbaccelerator.com/codelib/shell/shellex.htm
    OracleGuy

  • #3
    New to the CF scene
    Join Date
    Aug 2009
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks, looked at thew link, bit over my head. i had a guy doing things for me but he is no longer around.

    anyone what to work with me on this. (for $$$$ of course)

    e-mail me tedneese at hotmail dot com


    below is what i am trying to do.




    Private Sub imgGraphics_Click(Index As Integer)
    Dim strPath As String 'Path String
    Dim strPath2 As String '2nd path string
    Dim intFreeFile As Integer 'File handle

    'Path to setup
    strPath = App.Path & "\setup.exe"

    'Path for readme file
    strPath2 = App.Path & "\readme\install_instructions.pdf"

    'Install graphics
    If Index = 2 Then

    'Hide the form
    Me.Hide

    'Call setup program
    Shell strPath, vbNormalFocus

    'Unload the form
    Unload Me

    'Exit graphics
    ElseIf Index = 3 Then

    'Unload splash screen
    Unload Me

    'Open readme document


    Shell "\reader\AcroRd32.exe \readme\install_instructions.pdf"

    End If

    End Sub
    Last edited by tman62; 08-10-2009 at 10:58 PM.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •