If somehow you find yourself working for a customer with very strict security policies that don’t allow ActiveX components, you can still work with D2-Config even if you cannot install the activex component.
You can access /D2-Config/ConnectDialog.html, ignore the popups and login as usual, then you’ll be redirected to /D2-Config/interface.html?interfaceId=null# which is the page with D2-Config matrix.
Every time you click somewhere you’ll get a popup stating the C6 ActiveX is not loaded but you can simply ignore it, as most of the application will work.
If you need to perform a full import of a configuration, you can do so with the following code (note that this will reset D2-Config configurations):
getSManager(); session=sm.getSession("repository"); D2Session.initTBOEx(session,false); D2Config config=new D2Config(session); config.importZip(new File("full path to Zip file with configuration"), true, null, null, true, true, null); Map arguments = new HashMap(); arguments.put("-callerUrl", "http://server/D2/"); arguments.put("-all", Boolean.TRUE); D2Method.start(session, D2RefreshCacheMethod.class, arguments); sm.release(session);
You’ll need to add to your project d2-api.jar and c6-common.jar, mark as approved the dfc instance used by the program’s dfc, and set the java.security parameter as explained in D2 4.7/16.4 configuration in eclipse
Nice hint
LikeLike
[…] post I explained how to perform a full import of the D2 configuration without using D2-Config (D2-Config without ActiveX). You can also export the D2-Configuration to a XML file by using the bundled d2configutils in […]
LikeLike