|
发表于 2018-7-25 21:24:56
|
显示全部楼层
DIALOGS MESSAGE OFF
DIALOGS ERROR OFF
//-----------重命名----------
INT i=1
FOREACH toolpath IN folder('TOOLPATH') {
STRING thname=toolpath.Name
STRING toolname=toolpath.tool.name
STRING LIST StrList=tokens(toolname,"_")
STRING NewName=select(i<10,"0"+string(i)+"-"+$StrList[0],string(i)+"-"+$StrList[0])
RENAME TOOLPATH $thname $NewName
$i=i+1
}
DIALOGS MESSAGE OFF
DIALOGS ERROR OFF |
|