Showing results for 
Search instead for 
Did you mean: 

Mapping attributes for Solidworks integration

Hello Team,


I am trying to map the attribute for TC-Solidworks integration,

But i have come across below issue

in SWIM.XML file i have added below code for mapping attribute of my custom object,


<attribute_map cad_type="sldprt">

<cad_name value="Weight"/>

<pdm_name value="ItemRevisionSmiley Tonguea4CustomPartRevision.FormSmiley Tonguea4CustomPartRevisionMaster.pa4_weight"/>
<missing_attribute_action value="create"/>
<direction value="cadtopdm"/>


and after this addition of code in xml file, i have created txt file by using create_attr_mappings.bat file


in that txt file below code has been seen, which i doubt as incorrect


{ Item type="Pa4CustomPart"
Weight : ItemRevision.GRM(IMAN_Specification,Pa4CustomPartRevisionMaster).pa4_weight


SO here it is showing Iman_specification relation, and in Siemens documentation there they have mention same example, in which relation in txt file is "Iman_master_form"

before importing this file, i want to make sure that this file is correct or incorrect,


Please suggest





Re: Mapping attributes for Solidworks integration


Hi Ganesh,


I am doing the same thing recently. I will really appreciate if I can have some help. 


So we have a OOTB swim.xml. If I want to map these attributes, all I need to do is 


customize the swim.xml, run create_attr_mappings.bat to generate the 1.txt file. Then run export_attr_mappings to generate 2.txt file. Then merge 1 and 2.txt into 3.txt and import 3.txt back to TC. Is that right? 


Also, about <missing_attribute_action value="create"/>, let's say weight. So I don't have weight attribute in Solidworks, it will generate one I assume. When I want to assign a value (3kg) to that weight, Do I file->property, manually create a weight in Property Name, then in Value/Text Expression, type 3kg? I save it back to teamcenter, it will assoicate to your Pa4CustomPartRevision?


Finally, do you know how to get the allowed_item_type work. We have customized item type. How to I see the dropdown menu of item type in NEW part?/


I am a little confused as first has this task...


Thanks a million!!! 

Re: Mapping attributes for Solidworks integration

Step 1) Copy necessary files on TC server from client integration location mentioned in admin document.

(Swim.xml, create_attribute_mapping.bat, etc)


Step 2) Modify the swim xml to map the attributes like below,



<cad_name value="Material"/>   // property name in CAD                                          

 <pdm_name value="ItemRevision.a7_material"/>  // property resides on which business object

<missing_attribute_action value="create"/>   //creates the property in solidworks  

  <default type="String">TestMaterial</default>       // default values of the property

       <direction value="both"/>      // value modification from both ways  



 Step 3) run create_attr_mappings.bat in TC command propmt and generate the text file from this swim.xml


Step 4) if you have no other mapping with any other software, you can directly import this text file.



1) open the solidworks and create part, select want to create in Teamcenter,

2) now open properties tab and you should see custom proerties in the dropdown,

3) select the custom property and give any value and save

4) check in TC.