|
楼主 |
发表于 2024-5-7 10:26:16
|
显示全部楼层
目前我已经测试成功,文件名命名格式,代码+空格+名称。例:2532532 钢板
; ^7 r+ T8 c% V$ w! D' v, \3 r零件代码:
& M1 m0 }3 }- e: a8 B名称代码:Part.Extension.CustomPropertyManager("").Set("名称",Right(Part.GetTitle,Len(Part.GetTitle)-InStr(Part.GetTitle," ")))( M% D. l+ T$ i- w+ Z
代号代码:Part.Extension.CustomPropertyManager("").Set("代号",Left(Part.GetTitle,InStr(Part.GetTitle," ")))
: q. w1 P6 S* m/ q装配体代码:! \9 ]5 T: H! m3 a) ^9 t
名称代码:Assembly.Extension.CustomPropertyManager("").Set("名称",Right(Assembly.GetTitle,Len(Assembly.GetTitle)-InStr(Assembly.GetTitle," ")))
/ E3 L4 g! I" Q* p2 E* V7 W% q7 G) {代号代码:Assembly.Extension.CustomPropertyManager("").Set("代号",Left(Assembly.GetTitle,InStr(Assembly.GetTitle," ")))0 f5 W) L4 H) Z+ d
方程式设置如图: Q! E3 s4 t9 k- h' Z; Z. [4 Q
文件属性自定义如图
8 j7 U( l. [1 g% j# w$ I- |) K5 K4 x( H e! v2 ^$ w- X
注意,代码需要刷新后才能正确运行,自定义内需提前添加“名称”、“代号”两个属性+ d3 }. f }* e& o
|
|