Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
inet
active_desktop
active_scrptng
asp.components
asp.db
asp.general
comctl32
comp.packaging
components.dev
dbweb
dhtml_editing
docobjects
html_authoring
html_objmodel
iis
iis.ftp
iis.security
iis.smtp_nntp
indexserver
misc
mshtml_hosting
scripting.jscript
scripting.vbscript
sdk_setup
shell_objmodel
urlmonikers
webbrowser_ctl
wininet
  
 
date: Thu, 27 Mar 2008 10:20:47 -0600,    group: microsoft.public.inetsdk.programming.webbrowser_ctl        back       


Correct way of copying HTMLDocument   
Hello,

      What is the correct way to create an independent copy of an 
HTMLDocument in a BHO?  Specifically, what we want to do is:

      1) User navigates to a web page
      2) Create a copy of that web page
      3) Perform operations on the copy of the webpage, such that the 
instance that the user is working with is not affected by our operations.

      It is very important that the copy is an exact replica of the original 
document.  I understand that there are a variety of ways to do this, but 
some fail miserably and others have side effects.

      Any help would be greatly appreciated.

      Thanks,
      Dan
date: Thu, 27 Mar 2008 10:20:47 -0600   author:   Daniel McCann

Re: Correct way of copying HTMLDocument   
Daniel McCann  wrote:
>      What is the correct way to create an independent copy of an
> HTMLDocument in a BHO?  Specifically, what we want to do is:
>
>      1) User navigates to a web page
>      2) Create a copy of that web page
>      3) Perform operations on the copy of the webpage, such that the
> instance that the user is working with is not affected by our
> operations.

Try calling IHTMLDOMNode::cloneNode on document.documentElement.
-- 
With best wishes,
    Igor Tandetnik

With sufficient thrust, pigs fly just fine. However, this is not 
necessarily a good idea. It is hard to be sure where they are going to 
land, and it could be dangerous sitting under them as they fly 
overhead. -- RFC 1925
date: Thu, 27 Mar 2008 13:23:59 -0400   author:   Igor Tandetnik

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us