obj = xMCF.createInstanceWithContext("com.sun.star.awt.DialogProvider2", m_xContext );
XDialogProvider2 xDialogProvider = (XDialogProvider2) UnoRuntime.queryInterface( XDialogProvider2.class, obj );
m_xDialog = xDialogProvider.createDialogWithHandler( DialogURL, this );
m_xControlContainer = (XControlContainer)UnoRuntime.queryInterface( XControlContainer.class, m_xDialog );
XTopWindow xTopWindow = (XTopWindow)UnoRuntime.queryInterface( XTopWindow.class, m_xDialog );
if ( xTopWindow != null )
xTopWindow.addTopWindowListener( this );
}
catch (com.sun.star.uno.Exception ex)
{
ex.printStackTrace();
}