The process is as follows:
The control calls the implementation of the webbrowser IOleControl.OnAmbientPropertyChange in the SynchDOCDOWNLOADCTLFLAG function at http://csexwb2.googlecode.com/svn/trunk/cEXWB.cs to notify the webbrowser control of the property environment change inside the ActiveX host.
The webbrowser control then calls its host implementation IDispatch.Invoke to request an updated download control flag.
The IDispatch.Invoke host implementation for dispid DISPID_AMBIENT_DLCONTROL looks like this:
[DISPID (HTMLDispIDs.DISPID_AMBIENT_DLCONTROL)] public int Idispatch_AmbiantDlControl_Invoke_Handler () {return (int) m_DLCtlFlags; }
Check the Download and Execution Control box to see a list of flags that you can use to change browser behavior.
Sheng Jiang 蒋 晟
source share