Hello everyone,
I was hoping if someone can help me with an iLogic code to automatically generate file names for assembly files.
Basically my assembly contains some iLogic parameters which inlcudes says "alpha" (mm) and "beta" (in) both are numeric parameters.
So when the i change the value of "alpha" and "beta" i would want iLogic to save the assembly file with the following file name structure:
partname-alpha-beta.iam e.g.
partname = part1
aplha =100 mm
beta = 5 in then
file name should be: part1-100-5
and then save it aswell
Please help me with this i would greatly appreciate
Solved! Go to Solution.
Solved by bobvdd. Go to Solution.
Something like this perhaps ? alpha and beta will be expressed in the default document units.
Bob
Existingname = ThisDoc.FileName(False)
FileToSave = ThisDoc.Path & "\" & Existingname & "-" & alpha & "-" & beta & ".iam"
ThisDoc.Document.SaveAs(FileToSave , True)
Hi Mike,
Happy learn much of iLogic from this forum. Now, if we have existing assembly, and create new ipt or subassembly in that active assembly, how to get that active assembly's file name as prefix of new ipt or subassembly file name?
for example,
active assembly file name = NF100.980
and then create new part or subassembly inside that active assembly
new part file name should be : NF100.980-001
where "NF100.980-" automaticly suggested, and "001" will filled manually.
thank you
Can't find what you're looking for? Ask the community or share your knowledge.