1

I have managed to open IE via excel and navigate with it, but i am not able to run basic JS functions like "alert" or "prompt". (in browser, not MsgBox in excel) I have tried:

appIE.document.onLoad = "function() { alert(""text"");};"

Any idea?

2
  • You can only attach that handler to an existing document, which by definition has already loaded, so you're not going to see an alert from that. Have you tried attaching an event to an element in the document after it has loaded? I think also that last semi-colon is not required. Commented Nov 26, 2013 at 19:14
  • This was the only solution i could think of, is there any way i could show an alert on the webpage instead of excel? (regardless if it is an event or not) Commented Nov 26, 2013 at 19:19

1 Answer 1

6
appIE.document.parentWindow.execScript "alert('text');", "jscript"
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.