×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

UPDATE ASSEMBLY
2

UPDATE ASSEMBLY

UPDATE ASSEMBLY

(OP)
Hi, I write VB program to create .exp files for single component in my assembly. The problem is I have to import .exp file for every single part. I have about 100 component in the die or mold. Is there any way to write batch file to import all of them at once. Thanks

RE: UPDATE ASSEMBLY

ideauser,
   Can you be a bit more specific with what your trying to do?  What's the purpose of the .exp file?  What are your trying to accomplish?

Regards,
SS
CAD should pay for itself, shouldn't it?

RE: UPDATE ASSEMBLY

(OP)
Thanks for asking. For example I draw block of steel and dimension it as p0=4, p1=2, etc.. Then in the block.exp has p0=8, p1=3. If I go to tools, expressions and import block.exp in and OK. My block will change size. And in tool die design, it has 50 different components I have to hightlight each component and import the .exp file 50 times.
I am looking for batch file to update the big assembly at once. Thanks again

RE: UPDATE ASSEMBLY

2
What kind of file are you doing this to? Are you just modifying existing files for a new job and need to change the size of a bunch of components? Let me know I have an easier way to do this.

RE: UPDATE ASSEMBLY

(OP)
I do tool die design. For simple if my assembly file has to object: BLOCK1 & BLOCK2. BLOCK1 has Lenght=10, Width=5, Heigh=3. BLOCK2 has Length=6, Width=4 and Heigh=1. And I create 2 files: BLOCK1.exp with Length=20, Width=18, Heigh=2 and BLOCK2.exp with Length=2, Width=1, Heigh=1. In the assembly file, select BLOCK1 as make work part. Goto Tools menu, expression and inport BLOCK1.exp, OK. Then select BLOCK2 and make it working part. Update  the block with BLOCK2.exp same method as above. Then I have new assembly with 2 different block size. I am looking for batch file or how to write VB program which interface with ugs nx to update 2 blocks at once.

RE: UPDATE ASSEMBLY

In your top level assembly file you could have all your expressions for block one and two. So when you need to update them you could get by with only importing one exp file. So you need to link the expressions to the component files to do this.

For example in the top assy (lets call it top.prt) you have b1L=10,b1W=5,b1H=3 and so on. In block ones file you would have the expressions p0=top::b1L, p1=top::b1w, p2=top::b1H

Then all exp can be updated from the top.prt

RE: UPDATE ASSEMBLY

(OP)
Thank MBrookey for your wonderful help. The correct variable is p0="top"::b1l. And I found the Create link icon to link the variable to the top level assembly. It works both ways.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources