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: 

DGK macro

1 REPLY 1
SOLVED
Reply
Message 1 of 2
jsweatherbie
257 Views, 1 Reply

DGK macro

Hello im trying to look into a directory thats specified like for example " Y:\CNC\TOOLS\HOLDERS\HSK-100\" 
im trying to get a list of the DGK files directories. 

would i use .... string list $holders = dirname("Y:\CNC\TOOLS\HOLDERS\HSK-100\",Name)

1 REPLY 1
Message 2 of 2
Sean571
in reply to: jsweatherbie

 

string folderPath = "Y:\CNC\TOOLS\HOLDERS\HSK-100\"

//Gets all dgk files as a list
string list files = list_files("files", $folderPath, "dgk")

// You can then do something like have a user select a model from the list
INT selection = INPUT CHOICE $files "Select Model"
string filePath = $folderPath + "\" + $files[$selection]

 

Sean Wroblewski
Applications Engineer


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

Post to forums  

Technology Administrators