Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!nuzba.szn.dk!pnx.dk!fu-berlin.de!newsfeed.arcor.de!newsspool4.arcor-online.net!news.arcor.de.POSTED!not-for-mail Content-Type: text/plain; charset="ISO-8859-1" Message-ID: <34728788.KEVs06lIuy@PointedEars.de> From: Thomas 'PointedEars' Lahn Reply-To: Thomas 'PointedEars' Lahn Organization: PointedEars Software (PES) Date: Thu, 29 Nov 2012 23:20:24 +0100 User-Agent: KNode/4.4.11 Content-Transfer-Encoding: 7Bit X-Face: %i>XG-yXR'\"2P/C_aO%~;2o~?g0pPKmbOw^=NT`tprDEf++D.m7"}HW6.#=U:?2GGctkL,f89@H46O$ASoW&?s}.k+&. <1463591.kyDlKFe50m@PointedEars.de> Followup-To: comp.lang.javascript MIME-Version: 1.0 Lines: 69 NNTP-Posting-Date: 29 Nov 2012 23:20:25 CET NNTP-Posting-Host: 851099a8.newsspool1.arcor-online.net X-Trace: DXC=4CoP0hdF@QAX36K@\WTHGJic==]BZ:afN4Fo<]lROoRAnkgeX?EC@@@KV1GJ:PY58ADZm8W4\YJNLJ`:FmdeL>K@Vm>]fS?6G7HnN6S>5jH`lA X-Complaints-To: usenet-abuse@arcor.de Xref: csiph.com comp.lang.javascript:17380 Cezary Tomczyk wrote: > Thomas 'PointedEars' Lahn pisze: >> Cezary Tomczyk wrote: >>> Any idea how to refresh ActiveX controls without restarting IE? (or >>> probably any browser that support ActiveX). >> Several. Depends on what *exactly* you are looking for. > > I'll try do describe it how it works in steps: > > 1. The user goes to the requested page. Let's say http://www.test.com/ There is a real test.com. For examples, please use the .example TLD or the example.com SLD: If you have a problem with a Web site, however, it is of course best to post the real URI. > 2. I check if user has already installed required external software. > This software has a specified "ProgID" and ActiveX Class ID. > > Short code: > > var found, obj; > > if (typeof window.ActiveXObject !== 'undefined') { > try { > obj = new window.ActiveXObject('here is full ProgID'); > found = typeof obj !== 'undefined'; I do not think `obj' is ever going to be `undefined' at this line. You can just as well assign `true', or skip `found' and only work with `obj' (which you might want to initialize with `null'). See also jsx.net.http.Request.prototype._getXHR() in (a bit slow currently). > } catch (e) { > } > } > > 3. If "found" is true then this means that required external software is > installed and user will be moved to the next step. If not then I > triggering download process and must wait for end of installation. > External software will do all necessary changes inside ActiveX after > installation is complete. > > Now, I check every n seconds (using setTimeout instead of setInterval) > if required software is already installed. I can not check required > "ProgID" until I restart manually Internet Explorer. That's the problem. > > All I want is to refresh ActiveX list of all Controls and read required > data from ActiveX (check if required "control" is already installed) > without restart Internet Explorer. You should reconsider that approach. There should be an event for the successfully loaded ActiveX control which you can add an event listener for, or the control can execute code itself. PointedEars -- Use any version of Microsoft Frontpage to create your site. (This won't prevent people from viewing your source, but no one will want to steal it.) -- from (404-comp.)