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: 

is it possible to add a button in the bar, to run a macro?

2 REPLIES 2
Reply
Message 1 of 3
benettitec01
348 Views, 2 Replies

is it possible to add a button in the bar, to run a macro?

Hello,

 

there is a small arrow button in the view bar, and I ask if i can add another in my ribbon .

To understand what small button I mean, please see attached image

 

thanks for helping

greetings to everyone

 

 

Danny

 

 

 

 

small harrow button adding.png

2 REPLIES 2
Message 2 of 3
iamcdn79
in reply to: benettitec01

You can't add a macro to a button but you can add a dropdown to the menu and run a macro. See this thread


Intel Core i9 13900KF CPU
128 GB Kingston Beast DDR4 SDRAM
PNY RTX A2000 6GB Video Card
WD 1 TB SSD Hard Drive
Windows 11 Pro

Message 3 of 3

You can customize an MACRO BUTTON in QuickAcess Ribbon.

 

Choose the Icon you like, and add this macro on that button.

 

//this macro lists all macros in a drop down menu to run quickly


reset localvars
//INCLUDE "C:/dcam/pmill4/Macros/functions.pm4"

FUNCTION MAIN() {
//	CALL writeMacPath()

    //create a list of .mac files including the full folder path.
    STRING LIST $macFiles = list_files('files', 'C:\01-Dcam\Macros\Botao_Macro')

    //create a new list $macNames
    STRING LIST $macNames = {}
    FOREACH $File IN $macFiles {
        INT $Ok = add_last($macNames, TOKENS($File, "/")[SIZE(TOKENS($File, "/"))-1])
    }

    //display only the macNames in pulldown list
    INT $i = INPUT CHOICE $macNames "Select Macro"

    //run the selected macro
    MACRO ${$macFiles[$i]}
}

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

Post to forums  

Autodesk Design & Make Report