1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

VB.Net Web browser component steals focus

Discussion in 'Software Development' started by Ent, Jan 22, 2011.

Thread Status:
Not open for further replies.
  1. Ent

    Ent Trusted Advisor Thread Starter

    Joined:
    Apr 11, 2009
    Messages:
    5,467
    First Name:
    Josiah
    I'm working on a vb.net project that involves a Web browser component to preview the results of text I put in a text box above it (updating on every key press). It works fine initially on running the program, but if at any point I click within the area of the browser component it starts misbehaving. Basically from that point on the browser steals focus every time I press a key, which makes it pretty much impossible to type. I can set the web browser to pass focus back to the main text box on the previewkeydown event event, but that still requires that I press every button twice to type in the text box!

    From a lot of googling I've found that this is a known issue, but haven't found any better solution than the flawed one I mentioned of passing back control. Does anyone have any experience with this problem, or any ideas?

    PS my solution shouldn't ever require that the window of the web control be clicked, but does need access to the scroll bars (which cause the same issue). If there's a way to stop the control being clicked in the first place (and an alternative way of scrolling up and down) I'm all ears.
     
As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/976202

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice