INFO: ?????? ??? ???? ???? ?? ???? ???? ???? ActiveX

?????? ????????? ?????? ?????????
???? ???????: 172763 - ??? ???????? ???? ????? ????? ??? ???????.
????? ???? | ?? ????

?? ??? ??????

??????

??? ????? ???? ???? ActiveX ??????? "? ?? ???? ?????? ??????? ??? ?????? ??? ???? ???? ?? ???? HTML. ???? ???? ?????? ?????? ??? ????? ?????? ???? ???? HTML.

????? ??? ??????? ?????? ??? ??????? ?????? ??? ???? ???? ?? Visual C++ ??? Visual Basic ??? ???? Internet Explorer (IE) 3.x ?4.0.

??????? ????

???? ????

????? ???? ???? ???? ?????? ??? ?? ?????? ????? ??????? (SDK) ?? ActiveX ?SDK ???? ?????? ?? Internet Explorer 3.x ?4.0 ??? ???????. ?? ????? ???? ?????? ??? ???:
   window
      - location
      - frames
      - ...
      - document
         - links
         - forms
            - elements
				
?????? ???? ??????? ?????? ???? ??????? ??????. ????? ?????? ????? ????? ???? ????? ????? ??? ?????? ??????? ?????? ???. ?????? ?????? SDK ??????? ?????? ??? ???? ?? ????????.

????? ??? ?? ????? ???? ???? ??? ?????? ??? ???? ????

???? ???? ???? ?????? ??? (???????? ?? ??? ???????) ??????? ??? ???? ????? ??. ?????? ????? ??? ?? ???? ?????? ?????? ??? ???? ????. ??? ???? ??????? ???? ????? ???? ???? ???? ??????? ?? ????. ?? ???? ???? HTML ?????????? ???? ?????? ??? ???? ?????? ?? ???? HTML ?? ??????.

?????? ??? ???? ????

??? ????? ???? ???? ???????? "??????? ????????" ? "?????? COM. ????? ?? ??????? ?????? ?? ???? ?????? ?????? ??? ???? ?????? ?? ???? ???? ?????? ???? ?????? ???????? ?????? COM "??" ??????? ????????. ?????? ??? ??????? ??? ??????? ???????:
  1. ????? ??? ??????? ?????? ?? ???? ??????.
  2. ?????? ??? ?????? ?? ???? ??????.

??? ??????? ?????? ?? ???? ?????? (C++ ????)

???????? IWebBrowserApp (?? 3.x Internet Explorer 4.x)

?? IWebBrowserApp ????? ???? ??? ????? ?? ???? ???? "?????? ???". ????? ????? ????? (?? ????? get_document) ??? ?????? ????? vtable ???? ???? ??????? ??? ???? "??????? ????????" ?? ??????? ?????. ??? ??? ??????? ????? HTML ???? ??????? ???????? ?? ????? ???????? ??? ???? ???? ?????? ???? ???? ???? ??????? ??????. ??? ?????? ??? ???? ???? ???? ????? ??? ????? ??????:

  • ?????? ??? IWebBrowserApp ?? ???? HTML ????? ??? ???.
  • ?????? ??? ????? ????? IWebBrowserApp.
  • ?????? ??? ????? ???????? ????? ?? ???????.
????? ??? ??? ???? ?? ??????? ?????? (???? ????) ?? ???? ????. ?? ?????? ??????? ???????? ?????? ???? ????.

?????? ??? IWebBrowserApp

?????? ??? IWebBrowserApp ????? ?? ??????:
  1. ??????? ???? IOleClientSite ?????? ??? IServiceProvider. ?? ATL ???? ?????? ??? ?????? ???? ?????? ??? ?????? ??? ??? m_spClientSite ???? ??????. ?? ???? ???? MFC ???? ?????? ??? ??? ?????? ?? ???? ??????? COleControl::GetClientSite(). ?? ?????? ??? ????? IOleClientSite ?????? ???????. ???? ??????? ??? ?????? QI ?? IServiceProvider:
    pClientSite->QueryInterface(IID_IServiceProvider,
                              (void **)&pISP);
    						
  2. ?????? IServiceProvider IWebBrowserApp. ???????? IServiceProvider ? QueryService ???? ?????? ?????? ??? IWebBrowserApp:
          pISP->QueryService(SID_SWebBrowserApp, IID_IWebBrowserApp,
                            (void **)&pIWebBrowserApp));
    						
?????? ??? ??? ????? Internet Explorer 4 ?? ??????? ?????? ????? ?????? ??? ???? ????? IWebBrowser2 ??????? ?? ??? ???????? ????????:
   pISP->QueryService(IID_IWebBrowserApp, IID_IWebBrowser2,
     (void **)&pIWebBrowser2));
				
QueryService ????? QueryInterface ?? ??? ??? ???? ????? ???? ?? COM. ????? ??? ??? ?? ???? ?????? ???? IWebBrowserApp, ???? ???? ????? ????? ??? ???? ?? QueryService ???? ?????? IWebBrowserApp.

?????? ??? ????? ??????? ?? IWebBrowserApp

IWebBrowserApp ????? ??????. ???? ?? ????? ????? ?????? ????? get_Document. ???? ??????? ??? ?????? ??? IDispatch ??????? ?????. ????? ?? ???? ???? IDispatch ? ?? ?????? ??? ??????? ???????? ?????.

?????? ??? ????? ??????? ?????? ?? ???????

???????? IDispatch ?????? ??? ???? ? ?????? ??? ????? ???????? ????? ???????? ??????? ????????. ????? ??????? ?????? ?? ???? ???? ??????? ?????? ?? ???? ??????.

?????? ??? ??????? ?????? ?? ???? ?????? (C++ ????)

(Internet Explorer 4.0 ???)

???? Internet Explorer 4.0 ?????? ??? ???? ???? ???? ?????. ??? ????? ?? ???? ?????:
  1. ?????? ??? IHTMLDocument2 ?? IClientSite.

?????? ??? IHTMLDocument2 ?? IOleClientSite

????? ?? ???? ???? ?????? ??? IClientSite ???????. ??? ????? QI-ing IHTMLDocument2 ?? ???? ???? ???? ???? ??????? ??????.
   IOleContainer* pContainer = NULL;
   IHTMLDocument2* pDoc = NULL;

   pClientSite->GetContainer( &pContainer );
   if ( pContainer != NULL )
      pContainer->QueryInterface( &IID_IHTMLDocument2, &pDoc );
				
???? ?? ???? ??????? ?? ??????? ?????. ??? ?? ??? ????? ???? ?????? ??? ???? HTML ?? ??? ?? ??? ??????? Internet Explorer 4.0 ????? ??????? ?????.

?????? ??? IHTMLDocument2 ???? ???? ??????? ?? ???? ???? ??????? ??????. ?? ???? ??????? ?????? ?? ?????? vtable ?????? ???? ??????.

?????? ??? ??????? ?????? ?? ???? ?????? (???????? ????)

???? ??????? ????? "?????" UserControl ?????? ??? ???? ??????? ????????. ?? ????? Visual Basic ??????? ????? Internet Explorer ????? ???? ?? ??????? Script ?????? ???? IOmWindow.

?????? ?????? ?? ????? Visual Basic ??? ???:
Parent.Script.get_document.bgColor = "Blue"
				
??????? Parent ?????? ??? ???? ??????? ????????. ?? ??????? ???????? ????? ???? ??? ?????? ???? ???? ???? ??????? ??????. ?? ???? ?????? ??? ????? ??????? ?????? ?????? ??? ?? ???? ??? ?? ??????? ????????.

??? ????? ????? ??? ?? ????????? ???????? ??? ???:
Parent.Script.document.bgColor = "Blue"
				
??? ?? ???????? get_document ??????? ?? Internet Explorer 3.x ??? ???? ?? Internet Explorer 4.0. ??????? ?????? ?? ??????? ????? ???????. ???? ?? ?? Internet Explorer 3.x ?4.0.

?????? ??? ?????? ???? ??????

?????? ??? ?????? ???? ?????? ?????? ??? ??????? ??????? ????????? ???????? ??????? ????????. ?????? ??? Internet Explorer 3.x, ?????? ??????? ???????? ???. ???? ??????? ?????? vtable ?? Internet Explorer 4.0. ?????? ??? ???? ?? ????????? ???? ????? driller ?? SDK ???? ??????.

???????

???? ???????: 172763 - ????? ??? ??????: 27/???? ??????/1422 - ??????: 1.0
????? ???
  • Microsoft Internet Explorer 3.01
  • Microsoft Internet Explorer 3.02
  • Microsoft Internet Explorer 4.0 128-Bit Edition
  • Microsoft Internet Client Software Development Kit 4.01
????? ??????: 
kbmt kbfaq kbinfo KB172763 KbMtar
????? ????
???: ??? ????? ??? ?????? ???????? ?????? ????? ???? ????? ?????????? ????? ?? ????????? ?????? ????. ???? ???? ?????????? ???? ?? ???????? ???????? ?????? ????????? ????? ????????? ???????? ????? ???????? ?????? ?? ?????? ??? ?? ???????? ???????? ?? ????? ??????? ?????? ??? ??????? ?????? ??. ?????? ?? ???? ??? ??????? ???????? ????? ?? ???? ????? ?????? ??? ????? ??? ????? ??????? ?? ????? ?? ?????? ??? ??? ??????? ??????? ?? ????? ????? ????? ????? ?????. ?? ????? ???? ?????????? ??????? ??? ????? ?? ??????? ?? ????? ?????? ?? ??? ????? ?? ????? ??????? ?? ???????? ?? ??? ???????. ???? ???? ?????????? ???????? ??? ????? ?????? ??????? ??????
???? ??? ????? ??????? ?????? ??????????172763

????? ???????

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com