news.gmane.org wrote:
> XModel oModel =
> (XModel)UnoRuntime.queryInterface(XModel.class,oEvent.Source);
> if (oModel!=null) {
> System.out.println("Document URL is: " +
> oModel.getURL());
> }
> }
You should be aware that getURL() will return an empty string if the
document is an untitled one and as you can have more than of untitled
document it doesn't qualify as an identifier.
You could use the document (reference) itself as a unique identifier.
You then must register as a listener so you get a notification when the
document is disposed so that you can release your reference.
Best regards,
Mathias
--
Mathias Bauer (mba) - Project Lead OpenOffice.org Writer
OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS
Please don't reply to "[EMAIL PROTECTED]".
I use it for the OOo lists and only rarely read other mails sent to it.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]