Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

activate 2nd IExplorer instance

Status
Not open for further replies.

JohnMaas

MIS
Aug 14, 1999
18
US
Hi,

Does any body know how to activate a 2nd Iexplorer instance from a CF application ??

Thankx
 
I think you would have to go client side and use JavaScript window.open()

DeZiner
Never be afraid to try something new.
Remember that amateurs built the Ark.
Professionals built the Titanic
 
or just the target attribute in <a href> for opening a new windows on the click of a link.

 
You could use this to open a new instance, each time a user clicks the link:
Code:
<a href=&quot;mynewpage.cfm&quot; target=&quot;_new&quot;>link</a>

To open one instance and &quot;re-use&quot; that window, use this:
Code:
<a href=&quot;mynewpage.cfm&quot; target=&quot;_MyNewWindow&quot;>link</a>

When you use the second one, if no &quot;MyNewWindow&quot; instance exists, a new window will open and go to the page you specify. If the window has already been opened, it will use this window and take it to the new page. However, this will not force that window to receive focus. You can do this by using JavaScript in the head of the webpage you are calling. I haven't done this yet, but have been looking into. Here's some code I scavanged that makes sure the page stays on top:
Code:
<SCRIPT LANGUAGE=&quot;JavaScript&quot;>
 <!--
 var ident=null;
 var identCount = 0;
 
 function startFocusRetain()
{{
    focus();
    ident=self.setTimeout('resetIdent()', 2000);
}}

 function resetIdent()
{{
    if (identCount++<5 )
    {
       ident = null;
       startFocusRetain();
    }  
     else
     {
        close();
     }
}}
 //-->
 </SCRIPT>

You can also change _MyNewWindow to anything that makes sense in your application.

Hope this helps!
 
thats what i mean. didn't feel the need to explain plain old html though. but yeah, thats the simplest way.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top