// ***
// Activates all ActiveX controls on the page without needing to click on it
// ***
function activate_activex()
{
objects = document.getElementsByTagName("object");
for (var i = 0; i < objects.length; i++)
{
objects[i].outerHTML = objects[i].outerHTML;
}
}
Hi thanks for the code, But Shall we need to call this function in Page_Onload() event? If so please give the activate_activex() function calling statements.
ReplyDeleteAbsolutely. The reason I only have this function listed above is so that you can call it from any place you want, including Page_Onload().
ReplyDeleteIf you do this, you will loose all FlashVars in that page and also add LOTS of unwanted garbage parameters in the page...
ReplyDeleteThis is because outerHTML/ innerHTML DOES NOT return proper value.