File naming is an important consideration when planning an implementation, and DriveWorks affords complete flexibility in how files are named.
This document describes how files get named in DriveWorks, and how the names you choose interact with the concept of alternatives and driven alternatives so that you can build up libraries of parts that can be used again and again without needing to be generated for each specification that is generated.
The following key concepts are described in this document:
DriveWorks decides file names for models in a very simple way, for example, if we have the following assembly structure and file name rules:
Assembly Structure | File Name Rule | Result (when Specification 18 is created) |
---|---|---|
MyAssembly | DWSpecification | MyAssembly MyProject 0018 |
MyPartA | DWSpecification | MyPartA MyProject 0018 |
MyPartB | DWSpecification | MyPartB MyProject 0018 |
Here you can see that DriveWorks has simply suffixed the original component names, with a space, and the result of the Specification Name rule (in this case MyProject 0018).
DWSpecification is a Special Variable.
By default the Specification Name rule results in the name of the project with the SpecificationID formated to 4 leading numbers.
Another possibility is to tell DriveWorks to use the result of the rule as a prefix, for example:
Assembly Structure | File Name Rule | Result (when Specification 18 is created) |
---|---|---|
MyAssembly | "*"&DWSpecification&"*" | MyProject 0018 MyAssembly |
MyPartA | "*"&DWSpecification&"*" | MyProject 0018 MyPartA |
MyPartB | "*"&DWSpecification&"*" | MyProject 0018 MyPartB |
Here the * is used, first at the start of the rule, to remove the original file name; and then at the end of the rule to append the original file name.
It is also possible to tell DriveWorks not to use the original file name at all, for example:
Assembly Structure | File Name Rule | Result (when Specification 18 is created) |
---|---|---|
MyAssembly | "*A-"&DWSpecification | A-MyProject 0018 |
MyPartA | "*PA-"&DWSpecification | PA-MyProject 0018 |
MyPartB | "*PB-"&DWSpecification | PB-MyProject 0018 |
When removing the original file name it is important to include something that differentiates each model being built.
If this is not done you will end up with an assembly full of exactly the same components.
It is also possible to use an intelligent naming convention. This will allow DriveWorks to re-use a file that has previously been created.
The top level assembly will still require a unique name, if not nothing at all could be generated. But all sub-assemblies and parts can be assigned an intelligent naming convention.
Assembly Structure | File Name Rule | Result (when Specification 18 is created) |
---|---|---|
MyAssembly | "*A-"&DWSpecification | A-MyProject 0018 |
MyPartA | LengthReturn &" Long X"& DWVariableHeight &" High" | MyPartA 2745 Long X 698 High |
MyPartB | "*PB-"&HashMD5(LengthReturn&DWVariableHeight) | PB-C48CEAEBA9E04137B8E201A8D5DA8559 |
When using intelligent file names it is important to combine all the parameters that affect the outcome of the model into the name.
This ensures that DriveWorks will re-use the correct component when needed.