Reputation: 55
I am on the web, not client.
I need the user to press a button to execute some formula code and then execute this javascript:
function submit(){
var fein = document.getElementsByName("Payer_FederalEIN").item(0);
var address = document.getElementsByName("InternetAddress").item(0);
var pass1 = document.getElementsByName("Password1").item(0);
var xmlhttp;
if (window.XMLHttpRequest)
{// code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
}
else
{// code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
xmlhttp.open("GET","url,false);
xmlhttp.send();
}
}
When I use @URLOpen("javascript:submit()"), nothing happens and none of the formula code under that line is executed.
Is there a way to do this?
Upvotes: 0
Views: 1005
Reputation: 942
Why use formula language in this context? Change the button to Javascript and put submit() (or the entire function) in there.
Upvotes: 1