Click here to Skip to main content
15,879,348 members
Articles / Desktop Programming / MFC
Article

Simple VC++ DHTML hooking technique demonstration

Rate me:
Please Sign up or sign in to vote.
3.36/5 (9 votes)
21 May 2001 142.3K   1.5K   36   32
A sample code demonstrating how to use MSHTML lib.

Sample Image - dhtmldemo.gif

Introduction

This example demonstrates how to access DHTML object model and how to intercept the DHTML element events. It also demonstrates how to use connectionpoint with MFC. The demo program first loads up a sample HTML page which contains two button elements and a listbox element. Then it accesses button element DHTML object and intercepts its Click, DoubleClick, MouseMove, MouseOver, MouseDown and MouseUp events. After the program intercepts an event, it records the event information to the listbox element on the sample HTML page. The example shows that MSHTML is very useful for Internet and web programming. I hope this example would provide some help for any one who wants to use MSHTML library. (You need to download ie5_lib or later IE library to compile the demo project.)

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


Written By
Australia Australia
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions

 
GeneralDHTML Pin
jannathali9-Nov-09 2:55
jannathali9-Nov-09 2:55 
GeneralThank You! Pin
youngji20-Dec-06 21:11
youngji20-Dec-06 21:11 
GeneralNeed help!! Is there any way to find result code after CDHtmlDialog's Navigate method? ThanX Pin
dimak19-Apr-04 2:49
dimak19-Apr-04 2:49 
-
Generalproblem, please help Pin
kamkiram17-Mar-04 22:56
kamkiram17-Mar-04 22:56 
Generalprinter page count program Pin
kaligambal9-Jan-04 18:37
susskaligambal9-Jan-04 18:37 
GeneralYou forget to delete the Sink Pin
iProgram (WangYue)24-Aug-03 3:47
iProgram (WangYue)24-Aug-03 3:47 
Generalplz Help Me.....why don't work VTS_DISPATCH Pin
Jin430916-Apr-03 15:59
Jin430916-Apr-03 15:59 
QuestionHello,please tell me how can i get a flash EMBED's url? Pin
Member 2065426-Feb-03 20:55
Member 2065426-Feb-03 20:55 
GeneralWhat's the difference between ConnectButton1 and ConnectButton2 Pin
Hoyle6-Oct-02 16:22
Hoyle6-Oct-02 16:22 
QuestionHello,please tell me how can i get a flash EMBED's width and height? Pin
my_tar26-Sep-02 18:59
sussmy_tar26-Sep-02 18:59 
AnswerRe: Hello,please tell me how can i get a flash EMBED's width and height? Pin
Stephane Rodriguez.26-Sep-02 19:18
Stephane Rodriguez.26-Sep-02 19:18 
GeneralRe: Hello,please tell me how can i get a flash EMBED's width and height? Pin
26-Sep-02 22:58
suss26-Sep-02 22:58 
GeneralRe: Hello,please tell me how can i get a flash EMBED's width and height? Pin
Stephane Rodriguez.26-Sep-02 23:02
Stephane Rodriguez.26-Sep-02 23:02 
GeneralRe: Hello,please tell me how can i get a flash EMBED's width and height? Pin
my_tar27-Sep-02 15:24
sussmy_tar27-Sep-02 15:24 
GeneralRe: Hello,please tell me how can i get a flash EMBED's width and height? Pin
Stephane Rodriguez.28-Sep-02 5:57
Stephane Rodriguez.28-Sep-02 5:57 
GeneralRe: Hello,please tell me how can i get a flash EMBED's width and height? Pin
my_arj28-Sep-02 23:37
sussmy_arj28-Sep-02 23:37 
GeneralRe: Hello,please tell me how can i get a flash EMBED's width and height? Pin
Member 2065426-Feb-03 20:52
Member 2065426-Feb-03 20:52 
GeneralRe: Hello,please tell me how can i get a flash EMBED's width and height? Pin
my_ajr29-Sep-02 0:01
sussmy_ajr29-Sep-02 0:01 
AnswerPlease HELP: Question with Flash on a web page Pin
JDasari3-May-04 11:48
JDasari3-May-04 11:48 
GeneralCompiler problem. Pin
Chagit3-Feb-02 23:18
Chagit3-Feb-02 23:18 
GeneralRe: Compiler problem. Pin
14-Jun-02 5:52
suss14-Jun-02 5:52 
GeneralRe: Compiler problem. Pin
storein4-Mar-06 1:23
storein4-Mar-06 1:23 
GeneralRe: Compiler problem. Pin
abno29-Mar-07 22:28
abno29-Mar-07 22:28 
GeneralDHtmlHook - Pushing buttons does nothing Pin
GD36916-Dec-01 19:04
GD36916-Dec-01 19:04 
GeneralRe: DHtmlHook - Pushing buttons does nothing Pin
Anonymous12-Jul-02 11:34
Anonymous12-Jul-02 11:34 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.