Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Windows Forms / WinForm General / September 2007

Tip: Looking for answers? Try searching our database.

I need to be able to trap when the user clicks on a Web Browser control.

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
RMZ - 26 Sep 2007 16:14 GMT
So the .NET 2.0 web browser control does not provide a MouseDown or
Click event handler, but I have a need to trap on this. I would like
to know the best approach to accomplish this. I see Enter and Leave
event handlers on the control and I have tried to trap on these and
then check the MouseDown event on the parent, but this doesn't seem to
work.

Is there an approach I can use with API calls. I don't require an 100%
managed solution.

Thanks.
Sheng Jiang[MVP] - 26 Sep 2007 23:47 GMT
install a mouse hook and check if the source window is the webbrowser
control or its children.
Signature

Sheng Jiang
Microsoft MVP in VC++

> So the .NET 2.0 web browser control does not provide a MouseDown or
> Click event handler, but I have a need to trap on this. I would like
[quoted text clipped - 7 lines]
>
> Thanks.
Robbe Morris - [MVP] C# - 27 Sep 2007 14:47 GMT
As mentioned above, see if these windows api calls dealing with the mouse
are helpful.

http://www.eggheadcafe.com/articles/transparentform_send_mouse_click_to_desktop.asp

Signature

Robbe Morris [Microsoft MVP - Visual C#]
.NET PropertyGrid Control - ListBox, ComboBox, and Custom Classes
http://www.eggheadcafe.com/tutorials/aspnet/270e9432-d236-47e7-b1af-5cd3abe27a75
/net-propertygrid-control.aspx


> So the .NET 2.0 web browser control does not provide a MouseDown or
> Click event handler, but I have a need to trap on this. I would like
[quoted text clipped - 7 lines]
>
> Thanks.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.