[Solved] Missing button in sidebar code

Creating a macro - Writing a Script - Using the API (OpenOffice Basic, Python, BeanShell, JavaScript)
Locked
liip2043
Posts: 3
Joined: Thu Mar 13, 2025 4:02 pm

[Solved] Missing button in sidebar code

Post by liip2043 »

Note: For this sidebar code, when the button is clicked, the sidebar pops up, but the part <form:form form:name="SidebarForm"> <form:button form:name="MyButton" label="Click Me" onclick="vnd.sun.star.script:Standard.Module1.ButtonClick?language=Basic&location=application"/> </form:form> is not displayed in the sidebar. What's the problem? Please help.

Code: Select all

   <?xml version='1.0' encoding='UTF-8'?>
<oor:component-data 
    xmlns:oor="http://openoffice.org/2001/registry" 
    xmlns:xs="http://www.w3.org/2001/XMLSchema" 
    xmlns:form="http://openoffice.org/2000/form"
    xmlns:xml="http://www.w3.org/XML/1998/namespace"
    oor:name="CalcWindowState" 
    oor:package="org.openoffice.Office.UI">
    
    <node oor:name="UIElements">
        <node oor:name="States">
            <node oor:name="private:resource/toolpanel/my.webpage.extension/icons" oor:op="replace">
                <prop oor:name="UIName" oor:type="xs:string">
                    <value xml:lang="en">test</value> 
                </prop>
                <prop oor:name="Element">
                    <value>
                        <form:form form:name="SidebarForm">
                            <form:button form:name="MyButton" label="Click Me" onclick="vnd.sun.star.script:Standard.Module1.ButtonClick?language=Basic&location=application"/>
                        </form:form>
                    </value>
                </prop>
            </node>
        </node>
    </node>
</oor:component-data>
Last edited by MrProgrammer on Sat Apr 12, 2025 3:53 pm, edited 1 time in total.
Reason: Tagged ✓ [Solved] Must use Python for this task
OpenOffice 3.1 on Windows 10
liip2043
Posts: 3
Joined: Thu Mar 13, 2025 4:02 pm

Re: Missing button in sidebar code

Post by liip2043 »

help me thanks
OpenOffice 3.1 on Windows 10
liip2043
Posts: 3
Joined: Thu Mar 13, 2025 4:02 pm

Re: Missing button in sidebar code

Post by liip2043 »

help help help
OpenOffice 3.1 on Windows 10
Bidouille
Volunteer
Posts: 648
Joined: Mon Nov 19, 2007 10:58 am
Location: France

Re: Missing button in sidebar code

Post by Bidouille »

Locked