// create a configuration storage
try {
String sourceDeleteCfg = util.utils.getFullTestURL("delete.cfg");
String deleteCfg = util.utils.getFullURL(util.utils.getOfficeTemp(xMSF) + "delete.cfg");
util.utils.copyFile(xMSF, sourceDeleteCfg, deleteCfg);
XStorage xSubStorage = null;
Object o = (XInterface)xMSF.createInstance("com.sun.star.embed.StorageFactory");
XSingleServiceFactory xSSF = (XSingleServiceFactory)UnoRuntime.queryInterface(
XSingleServiceFactory.class, o);
Object[] props = new Object[2];
props[0] = deleteCfg;
props[1] = new Integer(ElementModes.READWRITE);
XStorage xRootStorage = (XStorage)UnoRuntime.queryInterface(XStorage.class, xSSF.createInstanceWithArguments(props));
xSubStorage = xRootStorage.openStorageElement("Configurations2", ElementModes.READWRITE);
XUIConfigurationStorage xConfigStorage =(XUIConfigurationStorage)UnoRuntime.queryInterface(XUIConfigurationStorage.class, xManager);
xConfigStorage.setStorage(xSubStorage);
tEnv.addObjRelation("XUIConfigurationStorage.Storage", xSubStorage);
}