Hi Mathias,

> Switching off the design mode with the dispatch API is done in the
> following way: (quote signs to avoid line breaks)
> 
>>sub designmodeoff
>>
>>  document   = ThisComponent.CurrentController.Frame
>>  dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")
>>  dim args(0) as new com.sun.star.beans.PropertyValue
>>  args(0).Name = "SwitchControlDesignMode"
>>  args(0).Value = false
>>  dispatcher.executeDispatch(document, ".uno:SwitchControlDesignMode", "", 0, 
>> args1())
>>
>>end sub
> 
> For switching it on you must change one line:
> 
>>   args(0).Value = true

Didn't know we have *that* cool helpers meanwhile, thanks for pointing out!

Ciao
Frank


-- 
- Frank Schönheit, Software Engineer         [EMAIL PROTECTED] -
- Sun Microsystems                      http://www.sun.com/staroffice -
- OpenOffice.org Database                   http://dba.openoffice.org -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

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

Reply via email to