Hello Fernand, On Tuesday 21 December 2010, 14:42, Fernand Vanrie wrote: > I trie to remove some buttons on the standard Toolbar > > I found some BASIC code made by Andrew Pitonyack, but i run in a error, > saying that "private:resource/toolbar/standardbar" is no valid element > for settings in the UIConfigurationManager
your code below checks for "private:resource/menubar/menubar" Obviously, if you ask for info about com.sun.star.ui.UIElementType.TOOLBAR, there won't be MenuBar info! > Please try this simple code from in a writerdoc > > oDoc = ThisComponent > > iToolType = com.sun.star.ui.UIElementType.TOOLBAR > > oFrame = oDoc.getCurrentController().getFrame() > oCfgManager = oDoc.getUIConfigurationManager() > oToolInfo = oCfgManager.getUIElementsInfo( iToolType ) > For Each x in oFrame.LayoutManager.getElements() > print x.ResourceURL > REM private:resource/toolbar/standardbar" is prentent > stoolbar = "private:resource/menubar/menubar" this is the resource URL for the MenuBar! May be a copy & paste mistake. Regards -- Ariel Constenla-Haile La Plata, Argentina
signature.asc
Description: This is a digitally signed message part.