Results 1 to 6 of 6

Thread: AxAcro PDF - can't scroll

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2020
    Posts
    9

    AxAcro PDF - can't scroll

    I'm relatively new to Visual Basic. I have an existing program that uses AxAcroPDF to display a PDF selected by the user. The user selects which of two document types they want, the program gets the path from the folder and displays the PDF. The program loads the path of the PDF to sfilename and does this:
    AxAcroPDF1.src = sfilename

    When the PDF is returned to the screen, only the top of the image displays, which is all that fits in the window. I can see a scroll bar, but it doesn't move when clicked on. How do I make the scroll bar move up and down on the PDF image?

    I've tried googling, most of the links I see are for C# and not VB.NET. I can't find any sample code or instructions for allowing the scroll bar to move up and down.

    Regards,
    Charlie

  2. #2

    Thread Starter
    New Member
    Join Date
    Sep 2020
    Posts
    9

    Re: AxAcro PDF - can't scroll

    I guess nobody knows...

  3. #3
    PowerPoster jdc2000's Avatar
    Join Date
    Oct 2001
    Location
    Idaho Falls, Idaho USA
    Posts
    2,393

    Re: AxAcro PDF - can't scroll

    Did you try translating any of that C# code that you found to VB.NET?

  4. #4

    Thread Starter
    New Member
    Join Date
    Sep 2020
    Posts
    9

    Re: AxAcro PDF - can't scroll

    I'm new to VB and have never done any C# but I suppose all I can do is try to figure it out.
    I'm surprised nobody's ever done this in VB.

  5. #5

    Thread Starter
    New Member
    Join Date
    Sep 2020
    Posts
    9

    Re: AxAcro PDF - can't scroll

    Well, this is weird... I got it to work.
    After spending the last week reading everything I could and every line of code I tried not being accepted by the compiler,
    my fix had nothing to do with the code.
    I started playing with the window size, dragging the border lines thinking I would just increase the size of the window to accommodate a larger portion of the PDF. When I did my build... instead of the window being larger, the scrollbar worked.
    I'm not even sure why it worked, but I accidentally fell backwards into the solution just playing with the window, dragging the borders out wider. Maybe this will help someone who has my same problem.

  6. #6
    PowerPoster jdc2000's Avatar
    Join Date
    Oct 2001
    Location
    Idaho Falls, Idaho USA
    Posts
    2,393

    Re: AxAcro PDF - can't scroll

    Nice find.

    Of course, when you are designing your form, VB has no idea whether the data you are going to display will need scrollbars, but you would think that the capability would still be active, just in case.

Posting Permissions

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



Click Here to Expand Forum to Full Width