I am working on an exampe for Live LibreOffice Python UNO Examples that dynamically inserts a control into a cell when it gets focus. (Lets say a currency control for this inquiry).
When the sheet is in design mode and I insert control it works a expected.
- Insert control.
- toggle Design mode (turn off)
So, When the cell gets focus I have put the doc into design mode, insert control, Turn design mode back off.
If I don’t put into design mode first there are issues such as the spin buttons are not rendered.
I am using a dispatch command SwitchControlDesignMode
to toggle design mode.
Is there another way?
I would like to avoid the user possibly putting into design mode and throwing the whole thing off.
Also I would really perfer not to use dispatch in this macro.
BTW: The control is removed when it looses focus.