Visualizzazione dei risultati da 1 a 2 su 2
  1. #1
    Utente di HTML.it
    Registrato dal
    Jun 2003
    Messaggi
    4,826

    errore js activex in vista

    ciao.
    ho la seguente riga di codice js che mi da errore in vista:

    var shell = new ActiveXObject('WScript.shell');

    mi dice che non riesce a creare il componente e in xp va!
    grazie

  2. #2
    Utente di HTML.it
    Registrato dal
    Jun 2003
    Messaggi
    4,826
    non sono sicuro che sia vista ,magari è una permission di ie , ma quale?

    posto tutto il codice:
    codice:
    <script language="javascript" type="text/javascript">
    function runApp() 
    { 
    var strUser=frm.user.value;
    var strPsw=frm.psw.value;
    
    var strCommand='explorer.exe /ftp://<'+strUser+'>:<'+strPsw+'>@ftpcairenet.it';
    //alert(strCommand);
    var shell = new ActiveXObject('WScript.shell'); 
    shell.run(strCommand, 1, 1); 
    } 
    </script>
    
    <html>
    <body>
    <form id="frm">
    <table>
    <tr>
    <td>
    User:
    </td>
     <td>
       <input type="text" id="user"/>
     </td>
    </tr>
    <tr>
    <td>
    Password:
    </td>
    <td>
     
    <input type="password" id="psw"/>
    </td>
     
    </tr>
    <tr>
    <td>
    <input type="button" name="button1" value="Accedi" onClick="runApp()" />
    </td>
    </tr>
    
    </table>
    </form>
    </body>
    
    </html>
    mi dice che non riesce a creare il componente ma non è vista,smette di funzionare quando lo lancio su un altro pc della rete o quando è publicato su un sito.

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.