It's all about the answers!

Ask a question

Calling a Runnable Jar from DNG Extension

Vaibhav S (655) | asked Jun 13, 1:27 a.m.


I have created a sample DNG Extension which I am able to add on my Dashboard.

I also have created a DNG Utility using OSLC which does some cleanup manipulations on DNG Artifacts depending on given scenarios. This Utility I am able to run as satndalone Runnable Jar.

Now i want to call this Utility as a Widget from DNG Dashboard. For the same i found that it needs to be done from a JS file of Widget, but couldnt find the exact process to be followed for the same,

Please let me know about it or any reference link for the same so as to how to call a runnable jar from JS file of Widget and deploying the Jar as well.

Please let me know in case of any issues.


Accepted answer

permanent link
Matthias Buettgen (23411825) | answered Jun 13, 12:08 p.m.

You should think about creating a web service out of your jar and deploy this to an application server. We recently did the same in one of our projects. Once you have done this, you can call the web service from the widget using the library and get the advantage that a user's session key is embedded into the request. So your service can run in the user's context.

Vaibhav S selected this answer as the correct answer

Vaibhav S commented Jul 12, 1:26 a.m.

Thanks Matthias .


One other answer

permanent link
Vaibhav S (655) | answered Sep 25, 10:35 p.m.

 Hi, this is the code i used for above query:

<?xml version='1.0' encoding='UTF-8' ?>
<ModulePrefs title='DNG Cleanup Widget' height='250' scrolling='true'>
<Require feature=''></Require>
<Content type='html'>
   Click on this Button to Run DNG Cleanup Utility
   <button onclick="myFunction()">Click me</button>
    <script >
    function myFunction() { 
    alert("Start DNG Cleanup Utility"); 
    var wshShell = new ActiveXObject("WScript.Shell");  
    alert("Creating Active X Object 3"); 

you will need to Enable the Active X objects in your Browser.


Your answer

Register or to post your answer.