Amministrazione generale > Utilità di creazione parte > Using Elements to Create XML Scripts > Putting it All Together – Applying Structure and Syntax > Examples of Common Part Selection Criteria > Example 2: Selecting Any CAD Documents with One or More of the Following Attributes
  
Example 2: Selecting Any CAD Documents with One or More of the Following Attributes
Here is an example XML script where the part selection criteria selects any CAD documents with one or more of the following attributes:
Parts and Assemblies with a name like “Turbine”.
Latest CAD documents only.
In the folder “Root Folder/Thermal_Power_Plant”
<Specifier>
<PartAction Class="wt.part.WTPart">
<FolderSpec CriteriaJoin="And">
<FolderCriteria ConditionJoin="And">
<FolderCondition Context= "Fullpath"
Operator="equal" Value="Default
/Thermal_Power_Plant"/>
</FolderCriteria>
</FolderSpec>
<PISpec CriteriaJoin=”Or”>
<PICriteria ConditionJoin=”Or”>
<PICondition Lookup=”name” Operator=”equal”
Value=”Turbine*”/>
</PICriteria>
</PISpec>
<PIVSpec CriteriaJoin="Or">
<PIVCriteria ConditionJoin="And">
<PIVCondition Version= "Latest"/>
</PIVCriteria>
</PIVSpec>
</PartAction>
</Specifier>
<?xml version="1.0 encoding="UTF-8"?>
<!--
Where
Indicates
<FolderCondition Context="Full"Operator="equal"Value="Default Folder/Thermal_Power_Plant"/>
The folder name.
<PICondition Lookup="name" Operator="equal" Value="Turbine*"/>
Parts and assemblies with a name that includes the word “turbine.”
<PIVCondition Version="Latest"/>
Only the latest CAD documents.