Hi Carsten, in the chapter 
http://wiki.services.openoffice.org/wiki/Documentation/DevGuide/WritingUNO/Disable_Commands
 it
is possible to re-enable those commands too. I started Open Office with some 
commands disabled and 
while Open Office was still running, i used the Enable Commands feature to 
enable commands and all those
commands which i had disabled earlier were now available to the user. Is there 
any way to prevent other UNO 
components/extensions from enabling Commands? Is there any way to lock a 
configuration file
(ex:org.openoffice.Office.Commands)? I want to prevent the disabled commands 
from being re-enabled by 
other running office extensions.

Thanks,
Praveen Reddy




--- On Fri, 30/5/08, Carsten Driesner <[EMAIL PROTECTED]> wrote:
From: Carsten Driesner <[EMAIL PROTECTED]>
Subject: Re: [api-dev] Preventing enabling of disabled commands by other 
extensions
To: [email protected]
Date: Friday, 30 May, 2008, 5:16 PM

Praveen Reddy wrote:
> hello,
>     in my extension i am disabling certain open
office commands to prevent users from modifying or copying documents. However,
after i disable them will i be able to keep them disabled? if other extensions
are going to invoke or enable those commands, how can i prevent them from doing
so? I have been exploring ways to disable other extensions, but the interface
XPackageManager does not provide us with methods to do so although it does
allow us to remove packages.  any suggestions  as to how i
can go about achieving this?
> 
Hi Praveen,

You can use the "Disable commands" feature to achieve your goal. The 
"disabled command" feature is the first instance which is asked for a

dispatcher in the dispatch chain. Nobody is able to circumvent this 
using an own dispatcher or dispatch interception. The only way to enable 
a command again is to remove the entry from the "disable commands" 
configuration. You can find more information in the Developer's Guide:

http://wiki.services.openoffice.org/wiki/Documentation/DevGuide/WritingUNO/Disable_Commands

Regards,
Carsten

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


      >From Chandigarh to Chennai - find friends all over India. Go to 
http://in.promos.yahoo.com/groups/citygroups/

Reply via email to