Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

Logical If Statement

Status
Not open for further replies.

Zuchetto

Petroleum
Mar 28, 2014
8
Hi,


I´m trying to use a logical if statement to link arrangements in a plate modeling.
When modeling, in dimension p1, I want to have the value 5 of my square side plate if my arrangement is set to arrangement 1.
And I want the value to be 10 if my arrangement is set to arrangement 2.

Is that possible?
 
Replies continue below

Recommended for you

p1=if(arrangement=1)(5)else(10)

Note that this will set p1=10 for any value other than 1.
 
I don't think there is a way to have an expression directly pull the arrangement name but using the Journal from here: posted by jpetach dated 30 Jan 13 12:35 in combination with interpart references should work.

Assuming your assembly hierarchy is set up like this:
>Assembly
>>plate

You should be able to run the journal, then create the following expression in the assembly:
Name = "plate"::p1
Formula = If(Active_Arrangement = "Arrangement 1") Then (5) Else (10)

Daniel Sikes
Design Engineer
Young Touchstone
NX 8.0.3.4
 
I cannot run any VB codes where I work. It´s blocked by default.
 
I apologize for my answer. Friday morning I was running on about 2 hours sleep and my brain equated "arrangement" with an expression named arrangement rather than an assembly arrangement.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor