Link to home
Start Free TrialLog in
Avatar of jmarbutt
jmarbutt

asked on

Call Javascript from VB6 Active X control

Ok I am a little rusty on VB6 because I have spent too much time in .net.

So my question is how can I call some javascript from a vb6 active x control that is placed on a page?

Thanks,

Jonathan
Avatar of TheSaint777
TheSaint777

Use the Windows API CreateProcess to launch your browser with the java script name in the command line parameter.
Avatar of jmarbutt

ASKER

Do you have an example?
Found an easier way. Use the shell command:

Shell "C:\Program Files\Internet Explorer\Iexplore.exe C:\test\JS Test.htm"

The first part is the path to the browser: C:\Program Files\Internet Explorer\Iexplore.exe
The second part is the path to the script file: C:\test\JS Test.htm
 
I think we are going in circles. Let me see if I can explain it a little better.

I have a page that has some javascript and an activex control, I want this active x control to call the javascript that is on the page with it, not open another browser window with in the active x control.

ASKER CERTIFIED SOLUTION
Avatar of TheSaint777
TheSaint777

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial