ADOxx and External ApplicationsADOxx and External ApplicationsRE: ADOxx and External ApplicationsNena Basinahttps://www.adoxx.org/live/c/message_boards/find_message?p_l_id=&messageId=16143002019-06-20T12:25:25Z2019-06-18T14:33:01Z<div class="quote"><div class="quote-content">Using the GET_PATH AdoScript command, you can retrieve the installation directory and construct the absolute path. </div></div><br />There is a problem with this implementation. When I use the GET_PATH command, the resulting path contains this string: <br /><div class="code"><span class="code-lines">1</span>"C:\Program Files (x86)\BOC\ADOxx15_EN_SA\" </div>which is part of a variable called <strong>sExportPath</strong>, saved for further use. <br />Notice the spaces in the <em>Program Files</em> folder name.<br /><br />In the case where I have to run the .jar, this command works if I add the quotes before and after the path variable.<div class="code"><span class="code-lines">1</span>SYSTEM ("cmd /c java -jar \"" + sJARpath + "\" " + sJARargs)</div><br />But in other cases, it doesn't seem to work, with or without the quotation, and I'm guessing that the problem might be because of the spaces. A couple of examples that <u>don't work</u>:<br /><br /><div class="code"><span class="code-lines">1</span>CC "AdoScript" FWRITE file: (sADOXMLExportFile) text: (sModifiedXml) binary:0</div>In this case the xml export file is never created, <em>ecode </em>is 1.<br /><br /><div class="code"><span class="code-lines">1</span>CC "Application" GET_PATH "ECAVI\\clingo.exe"<br /><span class="code-lines">2</span> #--> returns: "C:\Program Files (x86)\BOC\ADOxx15_EN_SA\ECAVI\clingo.exe"<br /><span class="code-lines">3</span>SET sClingoPath: (path)<br /><span class="code-lines">4</span>SYSTEM ("cmd /c " + sClingoPath + ....)<br /></div>In this case, the <em>clingo.exe</em> cannot run. <br /><br />I have tried different paths that don't contain spaces and they work perfectly.<br /><br />Any thoughts?Nena Basina2019-06-18T14:33:01ZRE: ADOxx and External ApplicationsNena Basinahttps://www.adoxx.org/live/c/message_boards/find_message?p_l_id=&messageId=15962552019-06-06T10:08:05Z2019-06-06T10:07:47ZThank you Wilfrid, it worked! <img alt="emoticon" src="https://www.adoxx.org/livehttps://www.adoxx.org/ADOxxORGv3-theme/images/emoticons/smile.gif" >Nena Basina2019-06-06T10:07:47ZRE: ADOxx and External ApplicationsWilfrid Utzhttps://www.adoxx.org/live/c/message_boards/find_message?p_l_id=&messageId=15935822019-06-05T15:40:56Z2019-06-05T15:40:56ZHi Nena - long time no see <img alt="emoticon" src="https://www.adoxx.org/livehttps://www.adoxx.org/ADOxxORGv3-theme/images/emoticons/happy.gif" ><br /><br />in order to overcome this issue, please put the JAR file into the installation directory of ADOxx in a separate folder. Using the GET_PATH AdoScript command, you can retrieve the installation directory and construct the absolute path. When distributing the tool, we will package the JAR into the installer and it will be part of your tool after installation.<br /><br />Best regards,<br />WilfridWilfrid Utz2019-06-05T15:40:56ZADOxx and External ApplicationsNena Basinahttps://www.adoxx.org/live/c/message_boards/find_message?p_l_id=&messageId=15891522019-06-05T15:36:40Z2019-06-04T11:09:00ZHello,<br /><br />I am implementing a tool on the ADOxx platform that takes advantage of its External Coupling functionality. In a few words, the steps of the implementation are:<ul style="list-style: disc inside;"><li>Export the designed models into XML</li><li>A Java program parses and translates the models into another format</li><li>The Java program executes the translated file and produces some results that are saved into a results file</li><li>The results file is then used to display the results back into the models in ADOxx </li></ul style="list-style: disc inside;"><br />Right now the XML exports of the models, the translated file and the results file are given with full local paths and the whole implementation in Java is used by calling the .jar file from an AdoScript script. But this kind of implementation cannot work since we want the tool to be used by anyone. So I have the following question:<ul style="list-style: disc inside;"><li>Can I add the .jar file into the library (so I can call it with db://...)? I have tried doing just that but the .jar couldn't run (it couldn't read the input file)</li></ul style="list-style: disc inside;"> <br />Thank you in advance.Nena Basina2019-06-04T11:09:00Z