Re: Changing JScript global variable values dynamically

From: Igor Tandetnik (itandetnik_at_mvps.org)
Date: 05/14/04


Date: Fri, 14 May 2004 10:33:32 -0400


"Peter" <peter1234se@yahoo.se> wrote in message
news:68de87e0.0405140043.732fff47@posting.google.com
> Using the IWebBrowser2 ActiveX plugin, I can access the html page's
> IHTMLDocument interface and from there get access to
> IHTMLScriptElement.
> But is there a way to actually go into running scripts and dynamically
> changing e.g global JScript variable values?

Call IHTMLDocument::get_Script - you get an IDispatch pointer of the
script global object. All global variables are properties on this
object, global functions are its methods. Just manipulate them via late
binding.

-- 
With best wishes,
    Igor Tandetnik
"For every complex problem, there is a solution that is simple, neat,
and wrong." H.L. Mencken