0 Replies Latest reply on Jan 23, 2007 11:48 AM by cpage cpage

    launch a .exe in a portlet

    cpage cpage Novice

      hi,

      i have to make a portlet which will be able to launch a heavy application.
      this is an old client-server application.

      for now, i use an javascript, and it's not working with firefox, just IE with security in the minimal level:

      <script type="text/javascript">
      <!--
      function exec(e){
      if (navigator.userAgent.indexOf('MSIE')> 0){
       var w = new ActiveXObject("WScript.Shell");
       w.run('\"'+e+'\" module=x210030'); //module=x210030 is a parameter
      }else{
       alert("Le lancement d'un exécutable n'est possible que sous Internet Explorer");
      }
      }
      //-->
      </script>
      
      [..]
      
      <h:commandLink onclick="exec('#{AppCpageV2Bean.cheminApplication}');" // this is the path of my exe.
      styleClass="transv" >
       <h:graphicImage style="border:none" value="/images/CPage.jpg"/><h:outputText value=" Cpage V2"/>
      </h:commandLink>
      
      


      this solution is very very very dirty ! (isn't it !)

      but i don't know how to do it in an other way.


      thanks for help,

      regards