excel - Rearranging custom buttons -


i new programming tried experiment excel ribbons. using custom ui editor. wanted use insertbefore , insertafter controls rearrange custom buttons. if not use unique namespace , insertafterq/insertbeforeq @ button level order of buttons not change, however, if use cannot see related macro (probably due namespace), therefore onaction not after clicking buttons. tried various combinations of idq cannot make work. below example correctly executes button 2 not in namespace specified. simple example:

<customui xmlns="http://schemas.microsoft.com/office/2006/01/customui" xmlns:x="mynamespace">     <ribbon>         <tabs>             <tab idq="x:customtab" label="my order form" insertaftermso="tabhome">                 <group idq="x:customgroup" label="my order form tools">                     <button idq="x:custombutton1" label="clear" size="large" onaction="deleteorder" image="deleteorder" />                     <button id="custombutton2" label="print" size="large" onaction="resetorder" image="resetorder" />                     <button idq="x:custombutton3" label="home" size="large" onaction="neworder" insertbeforeq="x:custombutton1" image="neworder" />                 </group>                             </tab>         </tabs>     </ribbon> </customui> 

is there way make onaction work within namespace? or there other way? many thanks, ts

do need namespace?

if want rearrange own controls, switch places in xml:

<customui xmlns="http://schemas.microsoft.com/office/2009/07/customui">     <ribbon>         <tabs>             <tab id="customtab" label="my order form" insertaftermso="tabhome">                 <group id="customgroup" label="my order form tools">                     <button id="custombutton3" label="home" size="large" onaction="neworder" image="neworder" />                     <button id="custombutton1" label="clear" size="large" onaction="deleteorder" image="deleteorder" />                     <button id="custombutton2" label="print" size="large" onaction="resetorder" image="resetorder" />                 </group>                             </tab>         </tabs>     </ribbon> </customui> 

if want place controls relative built-in controls, use insertbeforemso or insertaftermso, in "customtab". can tell need use namespace , idq-ids if combine controls customui-xml in different files.


Comments

Popular posts from this blog

magento2 - Magento 2 admin grid add filter to collection -

Android volley - avoid multiple requests of the same kind to the server? -

Combining PHP Registration and Login into one class with multiple functions in one PHP file -