Continue to Site

Welcome to MCAD Central

Join our MCAD Central community forums, the largest resource for MCAD (Mechanical Computer-Aided Design) professionals, including files, forums, jobs, articles, calendar, and more.

Parts assigned to layers

tomh

New member
All my parts have a "catagory" parameter. When I insert a part into an assembly I want Pro/E to automaticaly place that part on a particular layer. For instance, If I insert a bolt that has its "catagory" parameter defigned as "fastener" into an assembly, then that bolt would be assigned to the "fastener" layer in the assembly.


Thanks,


Tom
 
tom,


Add this to your config def_layer in option then put layer_assem_member put some space then fastener as value. Everytime you make an assembly Pro/E will create a layer named fastener, once you assemble any part with fastener parameter Pro/E willput it inyour fastenerlayer then you can blank the fastener layer thenall parts will blank.
smiley1.gif

Edited by: jayuy
 
Thanks jayuy. But here's my problem. I have large assemblies that contain hydraulic, power transmission, pneumatic, etc. parameters. My goal is to be able to hide these various layers individualy. This option only allows me to set one layer.
 
To further clarify, I want the ability to hide or, even better, to suppress "groups" of components by a parameter "CATAGORY" in the top level assembly.


Thanks
 
tomh,


I don't think you can create several layers automatically based from parameters in assembly. I think you can only create a layer manually for different component parameters. In my case i only create a layer in top assembly with same parameter names and set every component to the layer using all instances, for example if i want to add all hex_bolt to a layer named bolt, i just pick one hex_bolt and automatically all hex_bolt will be added to the layer.
 
I don't need to create the layers automatically. They are already in the assembly start up files. How do you acomplish what you described above?


Thanks,


Tom
 
Tom,


1. Create a layer with same name of your components parameter, for example as you can see in fig.1,I created a new layer named cover. note that if your top assembly consist of sub-assemblies, in creating the layer you shouldselect the Subassembly as active object if the componentis in a subassembly. Alsodon't add any default layer types.


View attachment 774


Fig.1


2. Add object to the layerby choosing componentand all instances as you can see in the figure below, then just pick one component, notice that i only choose one cover and all cover was blanked after i blank the layer.


View attachment 775


View attachment 776
 
Okay, it looks like you're "including" parts and components to layers manually.


I did some more tinkering and finally found the answer so that when you assembly a part in anassembly, that part is automatically assigned to a particular layer based on a parameter.


Starting from the top, I have a part file called "WASHER.PRT". This part has a "string" parameter called "CATAGORY" with a value of "FASTENER". I have a templateassembly file called "INLBS_ASM_DESIGN_GENERIC.ASM". This assemblyhas a layer called "FASTENERS".


I created a templateassembly filecalled INLBS_ASM_DESIGN_GENERIC.ASM. In this file I created a layer called "FASTENER". By right clicking on the layer I opened the "Layer Properties" dialog box. Under the "Rules" tab I clicked on the "Options" icon and selected "Independent".


View attachment 784


This allows you to select the "Edit Rules" icon opening the "Rule Editor" dialog box. I selected "Part" under the "look for:" and the "Look by:" pull down menus. (NOTE: if you want to set this up to search for assemblies, then select "Components".) Under the "Attributes" tab I choose "Expression" as the "Rule". Then, since I am looking for a string parameter, I selcted "String" under the "Type:" pull down menu and entered "CATAGORY" under the "Symbol:" pull down menu (the name of the parameter I'm searching for). I left the "comparison" value as "is equal to" and entered "FASTENER" under the "Value:" pull down menu since this is the same value as in the part files.


View attachment 785


Select the "ADD NEW" icon. Notice the new rule has been added to the "Query Builder" section.


View attachment 786


Select the "OK" icon. Now the new rule is listed under the "Rules" tab in the "Layer Properties" dialog box.


View attachment 787


Witha new assembly file created using the INLBS_ASM_DESIGN_GENERIC.ASM file I assemble my WASHER.PRT into the new assembly.Now the washer is automaticallyassigned to the FASTENERS layer.
 
Thanks tom for the info, now i can create a automatic layer of the assembly components when i start using WF2.0 next week.
 
jayuy, I found that if you create a new layer in order to add, by rules, any item it will not automatically add the items to the layer. To make this work, create a new layer. Do not give it a name. Go through the steps shown above. Exceptafter you click the "add new" icon, click the "Preview Results" icon. This will add all the items per the rules you created. Then select the "Options" pull down icon and select the "Save Query..." option. This will open the "Save Rules" dialog box. Enter the name of the layer you want to create. This will generate the layer with the correct name, rules, and all of the pre-existing items you wanted to add.
 

Sponsor

Back
Top