Community
PowerMill Forum
Welcome to Autodeskโ€™s PowerMill Forums. Share your knowledge, ask questions, and explore popular PowerMill topics.
cancel
Showing results forย 
Showย ย onlyย  | Search instead forย 
Did you mean:ย 

Ribbon DropDown menu trick

40 REPLIES 40
SOLVED
Reply
Message 1 of 41
dsmits
5667 Views, 40 Replies

Ribbon DropDown menu trick

 

 

some Kudos would be great ๐Ÿ™‚

 

after button 1 & 2 you can pretty much just copy and paste your ribbon button/macro/cmd right in order like you normally would edit your ribbon (notepad++). for button 1 and 2 you need to keep this format to a point.

Note---you cannot edit your tree in power mill, you will have to do your changes in notepad and import your ribbon in. But after you import it in you can move your dropdown to another ribbon.

so i would finish your drop down and then move to your desire ribbon

 

Note-- you can make drop downs from other dropdown items but does get pretty confusing. ill post that one too if i still have.

<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<entry application="PowerMill" application_version="1" type="uiRIBBONBAR" version="1">

  <entry type="uiCATEGORY">
    <resource key="uiLABELSTRING" value="TREE"/>
    <entry type="uiPANEL">
      <resource key="uiLABELSTRING" value="GROUP NAME"/>
      <resource key="uiRIBPANELALIGNMENT" value="false"/>
      <entry base_widget="Ribbon.Home.Macro.MacroRun" recursive="false">
        <resource key="uiLABELSTRING" value="THIS IS NUMBER 1"/>
        <resource key="uiBITMAP" value="CETEXTAROUNDCIRCLE"/>
        <resource key="uiCOMMAND" value="print = 1"/>
        <resource key="uiDYNAMICHELP" value="Text"/>
        <entry type="uiICONBUTTON">
         <resource key="uiLABELSTRING" value="This is number 2"/>
          <resource key="uiBITMAP" value="ROUTING"/>
          <resource key="uiCOMMAND" value="print = 2"/>
          <resource key="uiEDITTYPE" value="CommandButton"/>
        </entry>
      </entry>
      <entry type="uiICONBUTTON">
       <entry type="uiICONBUTTON">
          <resource key="uiLABELSTRING" value="This is Number 3"/>
          <resource key="uiBITMAP" value="ROUTING"/>
          <resource key="uiCOMMAND" value="print = 3"/>
          <resource key="uiEDITTYPE" value="CommandButton"/>
        </entry>
        <entry type="uiICONBUTTON">
          <resource key="uiLABELSTRING" value="This is Number 4"/>
          <resource key="uiBITMAP" value="ROUTING"/>
          <resource key="uiCOMMAND" value="print = 4"/>
          <resource key="uiEDITTYPE" value="CommandButton"/>
        </entry>
        <entry type="uiICONBUTTON">
          <resource key="uiLABELSTRING" value="This is Number 5"/>
          <resource key="uiBITMAP" value="ROUTING"/>
          <resource key="uiCOMMAND" value="print = 5"/>
          <resource key="uiEDITTYPE" value="CommandButton"/>
        </entry>
        <entry type="uiICONBUTTON">
          <resource key="uiLABELSTRING" value="This is Number 6"/>
          <resource key="uiBITMAP" value="ROUTING"/>
          <resource key="uiCOMMAND" value="print = 6"/>
          <resource key="uiEDITTYPE" value="CommandButton"/>
        </entry>
      </entry>
    </entry>
  </entry>
</entry>

ribbontree.pngplease like for sharing 

40 REPLIES 40
Message 21 of 41
Beta_Librae
in reply to: dsmits

Is that how you created the slide bar?


Kind Regards,
Not cnc, you can call me Peabrain
Message 22 of 41
barr.jarryd
in reply to: Beta_Librae

In regards to this, my ribbons keep defaulting back to the Home ribbon when I close out of a window; toolpath for example.

 

Is there a way to set it so that my Custom toolbar is the default to return upon closing a window?

 

Thank you

 

Jarryd Barr

Message 23 of 41
danmic7JH66
in reply to: barr.jarryd


@barr.jarryd wrote:

In regards to this, my ribbons keep defaulting back to the Home ribbon when I close out of a window; toolpath for example.

 

Is there a way to set it so that my Custom toolbar is the default to return upon closing a window?

 

Thank you

 

Jarryd Barr


Not that I'm aware of but you can add this command to the end of your macros to go back to your custom ribbon.

FORM RIBBON TAB UICATEGORY

 

Message 24 of 41
barr.jarryd
in reply to: danmic7JH66

Thank you

I will restructure to run just macros so that it will work this way.

 

Thank you

Jarryd Barr

Message 25 of 41
BS_agru
in reply to: Beta_Librae


@Beta_Librae wrote:

Curious how you made the slide bar shown in this thread. I think it could be a pretty cool addition to the software. What are you using it for?


Hi,

someone figured out how to add a Slidebar?

Message 26 of 41

 
 
Hello!
I don't have much experience with .XML files. But what is this code about? could you share an image or video of the final result?
I am not understanding the result.๐Ÿ˜–

Where did you insert this text in the option_menu.xml file inside the ribbon_customisation.xml file?
Message 27 of 41
Beta_Librae
in reply to: BS_agru

 Sorry, I think it's possible, but I don't have anything that works. Didn't ever really get a clear answer about how to create it, and I haven't figured it out myself.


Kind Regards,
Not cnc, you can call me Peabrain
Message 28 of 41
BS_agru
in reply to: Beta_Librae


@Beta_Librae wrote:

 Didn't ever really get a clear answer about how to create it, and I haven't figured it out myself.


 

...dito...๐Ÿ™„

Message 29 of 41
johnc4668
in reply to: dsmits

@dsmits @barr.jarryd @Beta_Librae @danmic7JH66   This post has me intrigued and i cant quit this! Take a look at my xml file here if you would. I have the drop down button on my ribbon but i am stuck on how to add more macro buttons to the drop down. Heres part of my xml and my ribbon screen shots:

 

</entry>
<entry type="uiRIBMENUBUTTON">
<resource key="uiLABELSTRING" value="Drilling Methods"/>
<entry type="uiPUSHBUTTON">
<resource key="uiLABELSTRING" value="3ax Dm Standard Steel"/>
<resource key="uiBITMAP" value="STRATEGY__METHOD"/>
<resource key="uiCOMMAND" value="MACRO &quot;Z:\Software\PowerMill\Macros\3ax Dm Standard Steel.mac&quot;"/>
<resource key="uiUSERDATA" value="Z:\Software\PowerMill\Macros\3ax Dm Standard Steel.mac"/>
<resource key="uiEDITTYPE" value="MacroButton"/>
</entry>
</entry>

 

2021-09-15_9-08-24.png

 

 

 

 

 

 

Message 30 of 41
glaubergimenez
in reply to: johnc4668

I got this somewhere on this forum. Merits for the Creator.

 

Import this XML and edit in notepad ++, how many instances would it solve?

Then move the Menu according to the image.

 

move_menu.jpg

Message 31 of 41
BS_agru
in reply to: johnc4668

Hi,

look at my Sample.xml

Message 32 of 41
rui_rita
in reply to: johnc4668

Hi @johnc4668 

this part is a button, just  copy/paste and change values as many buttons you need to add

<entry type="uiPUSHBUTTON">
<resource key="uiLABELSTRING" value="3ax Dm Standard Steel"/>
<resource key="uiBITMAP" value="STRATEGY__METHOD"/>
<resource key="uiCOMMAND" value="MACRO &quot;Z:\Software\PowerMill\Macros\3ax Dm Standard Steel.mac&quot;"/>
<resource key="uiUSERDATA" value="Z:\Software\PowerMill\Macros\3ax Dm Standard Steel.mac"/>
<resource key="uiEDITTYPE" value="MacroButton"/>
</entry>



Os melhores cumprimentos | Best regards
Rui Rita
________________________________
NEWCAM, Lda.
Message 33 of 41
johnc4668
in reply to: glaubergimenez

Yes, this was the same file i got it from but didnt need the command button "my button 1". I want to add more macro buttons "my button 2" to this drop down but not sure how to edit the xml file. Can you copy buttons in the customise ribbon window in powermill, didnt think you could?
Message 34 of 41
glaubergimenez
in reply to: johnc4668

The file that @BS_agru sent, I think is more prepared for what you need, but without icons. It's a very interesting option once you get familiarized with the menu. ๐Ÿ‘๐Ÿ‘

Message 35 of 41
rui_rita
in reply to: johnc4668

@johnc4668  you have to edit your xml file in text editor.

and any change to the dropdown menu you should always use a text editor. any change you make in powermill window, you could be messing  with the dropdown menu.

 



Os melhores cumprimentos | Best regards
Rui Rita
________________________________
NEWCAM, Lda.
Message 36 of 41
johnc4668
in reply to: dsmits

@glaubergimenez @rui_rita @BS_agru  Got it! You guys rule! Love this forum. All good now

 

As someone previously said i too am playing with powermill buttons like a kid now ๐Ÿ™‚

 

2021-09-15_10-44-27.png

Message 37 of 41
BS_agru
in reply to: johnc4668

๐Ÿ‘ Thanks especially to @dsmits & @NathanWoodward !

Message 38 of 41
PGI-49
in reply to: dsmits

Is it possible to directly call in a strategy template and what is the code? I can't seem to get it to go for some reason.

Message 39 of 41
tiago.coelhoMEKWZ
in reply to: dsmits

Thanks for your help!

 

One sugestion, use 'Ribbon.FeatureGroup.Draw.DrawOptions' instead 'Ribbon.Home.Macro.MacroRun' if you don't want your drop down button "clickable".

 

It is possible to create a tree like that 

tiagocoelhoMEKWZ_0-1643646518259.png

just do an base_widget inside another.

tiagocoelhoMEKWZ_1-1643646642819.png

 

 

 

Message 40 of 41

Hello Sir,

I am trying to make drop down menu with child button. I attached my sample file here. But it throws error  "failed to import the ribbon customization". please do the needful.

 

Thanks

 

 

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Technology Administrators


Autodesk Design & Make Report