×
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

Macro Writing... Could somone knock this up?

Macro Writing... Could somone knock this up?

Macro Writing... Could somone knock this up?

(OP)
Hi,

I realise this is a little cheeky, but it's less than a month until I start my new role and I need to get as much done in my present role as possible. Some might ask 'why bother, you're going to a new job?', as it's within the same company I don't want to let them down and do nothing for the final month... :)

Anyway, enough of that cr4p. My problem is with Family of Parts. At this company we have a lot of products that have a base set of dimensions, then the customer has a specific shaft size and we machine the product out to suit. This creates a lot of detail drawings, so we use FoPs. But here's the problem, when you populate out a FoPs the part members have no mass until you go to Physical Properties and press the Update button. As I'm the one creating most of these to start with (from 2D tabulated drawings) is it easy for someone (and here's the cheeky bit) to write a macro that does the following?

- I select and open up the file,
- I press a macro button,
- The part gains a mass (macro updates physical properties)
- The part gets saved and closed
- I move onto the next file...

Feel free to flame me :)

Cheers,

M

RE: Macro Writing... Could somone knock this up?

Hi M,
A quick suggestion here -
Are the parts all the same material ?
If so create a template part model and do the initial calculation for the mass props.
Once this has been done, delete the body from the model. and update again.
Now, when you create export a family member model use this as the template.
When you have created them use the OpenSave routine that comes with Solid Edge and the mass properties will update.
I haven't tried this so can't be sure it will work, and I realise it doesn't help with existing stuff.

bc

RE: Macro Writing... Could somone knock this up?

(OP)
Hi Beachcomber. I've tried what you suggested but the mass still does not update in the family member file. It does open and then save each file in term, but as for updating the mass it misses it :(

I'll try again, maybe I'm missing something. Ah well... enhancement request coming up!

Cheers,

M

RE: Macro Writing... Could somone knock this up?

Hi M,
It must be that when the new file for the family member is created the mass has to be initially calculated as for any new part and only when this has been done will a Save force an update.
I tried modifying the OpenSave routine to do the job, but I have VB Express 2005 (free download from Microsoft).
When I open the original VB code it converts to the new format and gives me a load of errors that I don't have the knowlege to correct.
If I get time I'll try and do something, but don't hold your breath as I'm back to work tomorrow after 7 weeks off.

By the way, don't know if you read my post on the multi-replace part macro, but I HAVE got that working. There are a few 'glitches' that I don't know how to correct, but it does what I want it to.

bc

 

RE: Macro Writing... Could somone knock this up?

Hi M,
Just another suggestion for you.
Create a new assembly file and drag in a load of the family member parts.
Then try using 'Physical Properties Manager" to assign material/density to each part. I think this should update each one.

bc

RE: Macro Writing... Could somone knock this up?


..yes this will work but do not forget to SAVE the
assembly after you've finished otherwise the parts
will not get saved. The assembly can be deleted
afterwards.

dy

RE: Macro Writing... Could somone knock this up?

(OP)
Hi,

Thank you for that it really did work just fine! The only thing that I spotted that was different was the non displaying of the Triad... I cannot work out why it's not though.

M

RE: Macro Writing... Could somone knock this up?

then get into Tools --> Optiones --> View there is an Option
to show/not show the orientation triad. Maybe it's OFF

dy

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