Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Is it possible to define a enumeration type expression? 2

Status
Not open for further replies.

JerryWong

Aerospace
Jul 31, 2015
16
0
0
HK
So as the value of expression "A" can only be 1, 2, 3, when a part has several specs. I watched the video "Attributes and Expression Templates" by John. It uses a List Type attribute in Attribute Templates. But is it possible to do this more directly just in expressions dialogue box? Beginner to this. It will be great thankful if any advice to this.
 
Replies continue below

Recommended for you

First, let me preface my response by saying I'm not really sure of what the question is.

For this device the only available options for the adjustment are even numbers between 2 and 12.
cut_guide_hesiqr.jpg


These are the expressions used to take any input but return only even values between 2 and 12.
limited_expression_jqcwlp.jpg


if(CUT_LEVEL<=2)(2)else(if(CUT_LEVEL>=12)(12) else((2+(round((CUT_LEVEL-2)/2))*2)))

For our example - if(CUT_LEVEL<=1)(1)else(if(CUT_LEVEL>=3)(3) else(round CUT_LEVEL))), where "cut_level" would be replaced by the expression name of your choice.
 
Make this way:
Create a expression like "D1" = 10
Crate a expression like "D1_options" = {10,20,30}

Now the D1 expression will have a list of options.


Gelson Z. Nicoletto
Eng. Supervisor
Mould Design
Brazil
 
Yes, gelsonnicoletto you got what I mean. But I'm too stupid to understand how to do in detail. D1 and D1_options don't have any association?
 
So I tried Gelson's tip. It took a while to notice the arrow in the formula field that displays the selection list.

options_zrfnyk.jpg


It does list the available options but you can still manually enter any value you want.
 
Status
Not open for further replies.
Back
Top