Results 1 to 4 of 4

Thread: WebBrowser ActiveX Control

  1. #1
    Guest

    Post

    I've embedded the webbrowser control in an ActiveX control and I wanted to know if there was any way to get rid of the Scrollbar.

    I've read through the microsoft documentation and it seems that the "Scroll=no" in the body tag is ignored.

    I've also tried using an HTA format instead but there is no way to tell VB that the script is for an HTA file and not an HTML file.


  2. #2
    Serge's Avatar
    Join Date
    Feb 1999
    Location
    Scottsdale, Arizona, USA
    Posts
    2,744

    Post

    What you can do is to place WebBrowser control inside of the Picturebox to achieve this:

    Code:
    Private Sub Form_Load()
        With Picture1
            .Left = 0
            .Top = 0
            .Height = ScaleHeight
            .Width = ScaleWidth + 100
            WebBrowser1.Navigate "www.vb-world.net"
            WebBrowser1.Move ScaleX(-12, vbPixels, vbTwips), _
                            ScaleY(-19, vbPixels, vbTwips), _
                            ScaleX(Width + 20, vbPixels, vbTwips), _
                            ScaleY(Height + 20, vbPixels, vbTwips)
        End With
    End Sub
    ------------------

    Serge

    Senior Programmer Analyst
    [email protected]
    [email protected]
    ICQ#: 51055819

  3. #3
    Guest

    Post

    I'm sorry, I don't see how this code puts the webbrowser inside of the picture box.

  4. #4
    Serge's Avatar
    Join Date
    Feb 1999
    Location
    Scottsdale, Arizona, USA
    Posts
    2,744

    Post

    I meant, that you have to put Picturebox on the form and then draw WebBrowser contrl inside of the Picturebox......then use the code above.

    ------------------

    Serge

    Senior Programmer Analyst
    [email protected]
    [email protected]
    ICQ#: 51055819

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