cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Need to share some code when posting a question or reply? Make sure to use the "Insert code sample" menu option. Learn more! X

Automatically Suppressing/ resuming features in a group or layer using pro program

BrianL
5-Regular Member

Automatically Suppressing/ resuming features in a group or layer using pro program

Is it possible to suppress layers using relations or pro program?

 

I have a part with all of the features possible built in and I suppress the features I don't want using parameters, relations and the model pro program. 

 

The problem I am having is when I need to add another feature to a group. When the new feature is added to the model tree in the existing group of features, the model program automatically adds an "end if" statement before the feature and the existing conditional statement after it. This essentially creates an island in the middle of the group that does not become suppressed with the group around it. On simple parts this is not a big deal as I can go in and fix it easily enough, but as the parts get more complex it gets much more complicated. Also, none of my coworkers are knowledgeable enough to editing pro programs at this time.

 

What I want to do is put all of the features that should be grouped together on a single layer and then just use relations or pro program to suppress or resume the layer. Then I can just name the layers by the customer option and everyone will be able to add features to the layer as needed. 

4 REPLIES 4
tbraxton
21-Topaz II
(To:BrianL)

I do not think a relation will execute a suppress command. You can definitely select for suppression all of the features in a group or on a layers using the search tool. I have used mapkeys to resume and suppress features by layers but not Pro/Program.

 

I have not tested this in the context of Pro/Program but it should work for selection.

 

You can use the search tool to select all members of a group for inclusion in a layer. By extension you should be able to create a rule to assign features to a layer that should update each time the model is regenerated. This may alleviate the Pro/Program issue with adding ENDIF, worth a try. If this does not work consider adding markers (I use empty annotation notes) to the model tree and ungrouping the features and then making a rule to add all features between the markers to a layer. The markers will have a unique feature ID that will allow you to track them no matter where they move in the tree.

 

Group selection using search toolGroup selection using search tool

========================================
Involute Development, LLC
Consulting Engineers
Specialists in Creo Parametric
BrianL
5-Regular Member
(To:tbraxton)

Thank you for the quick reply. 

 

I am able to get the features assigned to a layer no problem. The part I can't figure out is how to actually suppress a layer or the contents of a layer from pro program. Is that even possible? Is there a better way to model a configurable part?

 

I should probably mention that I am running creo 4.

 

Thanks.

tbraxton
21-Topaz II
(To:BrianL)

I am not an expert with Pro/Program but I have looked at using it to execute some other commands and struck out. I Don't think Pro/Program has the ability to suppress the layer because that is done through the new UI elements.

 

In terms of managing configurations there is Creo Options Modeler extension. I know very little about it but it may make configurations mush easier. You would have to buy that but I am sure a trial license would be offered to test it.

 

There are multiple options available for "configuring" parts/assemblies such as simplified reps I would need to more about the design hierarchy and what needs to change to offer more guidance on that.

 

There are also Excel based configurators that can control a master assembly and eliminate parts for different versions. Otis elevator had developed one back in the 90s and I am sure the options have improved since then.

 

Family tables work for things like bolts/nuts etc. I am not a proponent of using them to represent complex geometry/models especially if you are using Windchill. They can become a nightmare to manage as complexity expands. Strictly within Creo I would try the top down design tools and Pro/Program rather than family tables.

========================================
Involute Development, LLC
Consulting Engineers
Specialists in Creo Parametric
tbraxton
21-Topaz II
(To:BrianL)

I found some old reference material that is relevant to what you are working on. It may be useful. This does not use layer for suppression but suppresses features explicitly.

 

To suppress an entire group programmatically, include the statement if <value = no for a yes/no parameter> before the group header line, and the syntax ENDIF after the last line in the group. All members of the group are suppressed.
Note: In Pro/PROGRAM, all groups contain a group header, which is identical to the group name.

Suppressing Single Features That Are Members of a Group
You can suppress and resume individual features that are members of a group, provided you have set the configuration option del_grp_memb_ind to yes. To suppress group members in Pro/PROGRAM, use the same syntax that you use to suppress an entire group, as shown in the preceding paragraph. However, the placement of the syntax is different. Instead of placing the lines before and after the entire group, you place them before and after the single feature within the group, as though you were suppressing any other single feature that is not a group member.
To resume the individual feature, delete the lines if cvalue = no> and endif from the beginning and end of the feature.
Note: In order to suppress individual members of a group, you must set the configuration option del_grp_memb_ind to yes.

  

========================================
Involute Development, LLC
Consulting Engineers
Specialists in Creo Parametric
Top Tags