Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

Automating Description field between part and drawing.

Status
Not open for further replies.

Finethread

Mechanical
Mar 30, 2006
82
Is there a simple way to have the Description field in the part Save dialog box, automatically populate the Description field in the Drawing created from that part?

I noticed that using the Description field automatically creates the field in the Custom Property table but does not work the other way around.

I did check previous posts and FAQs but couldn't find anything. Also, at the moment, the search feature is down.

Thanks in advance.
 
Replies continue below

Recommended for you

In you drawing template, RMB in the field and select edit sheet format. In your description field, type $PRPSHEET:"Description"
Exit the note. RMB, select edit sheet. Save template. Save sheet format.

Jeff Mirisola, CSWP
CAD Administrator
SW '07 SP2.0, Dell M90, Intel 2 Duo Core, 2GB RAM, nVidia 2500M
 
To expound upon what Jeff said... you can't make the custom property from the part file automatically propagate to a custom property in the drawing file. You can link a note on the drawing to the "Description" (or any other) custom property of the part, but the "Description" custom property of the drawing file will not change. You may also be able to link the Description custom property of a drawing to the Description custom property of a part (I haven't checked this, but I think it's possible). However, you won't be able to do it automatically without some type of macro.
 
Clarification.....The field I'm refering to is not the Description field in the drawing/template, but the Description field in the Save dialog box.

I want the ability to show descriptions in the feature managers as well as pull these descriptions into PDMWorks.
 
Thanks for the suggestion re macro...but if you have to run a macro and supply input, might as well just cut and paste the description from the part to the drawing.

If someone can write a macro that auto-assigns the Description from the part to the drawing (or assembly) upon Make Drawing from Part or Make Assembly from Part, it would be appreciated.
 
or Make Assembly from Part

Did you really mean this? Do you want the part desription copied to the assembly description, or did you mean to say "Make Drawing from Assembly"?

If so, I really don't think you're going to be all that happy with a macro. Ideally it should be a little bitty add-in. The macro version would have to be run once during the SW session prior to creating any new drawings. The reason is that it has to be run in order to start watching the user's actions and monitoring for events. You can, however, add parameter switches to the SW shortcut on your desktop to force it to run a macro on launch.

Also, there is no event for "Make drawing from part" or assembly. That's not really what you want anyway. What if the user creates a new drawing by choosing File->New? What needs to happen is that when a new drawing view is created (any new view), the macro will catch that and check the drawing's custom properties for existence of the "Description" property and whether or not it is filled out. If no data exists, the macro copies it from the referenced part or assembly.

Maybe someone here will write that macro for you for free, but I sort of doubt it. The motivation is minimal. There are requests for macros here all the time. Personally, I've written quite a few and posted them. However, the task has to meet some combination of these criteria:

1. The challenge is interesting, leading me to investigation of a new area of SW.
2. It's a macro that I perceive could be useful to multiple people.
3. It's a relatively simple modification of one I've already written.

It also helps when it's not a direct request by a poster for someone else to do all the work for him/her.
 
Sorry I asked, I'll figure it out myself.

Thanks for the posts.....
 
Sorry if I came across as a jerk. I wasn't intending to berate you personally. I was just stating the way things are. If you've poked around the site much, you'll see that I've posted quite a few macros. I was just trying to explain to you why some people get "free" code handed to them and others don't. I think you'll find that most people here are extremely helpful and willing to teach if you look like you're putting forth some effort. "I'm trying to write a macro to..." or "I'm new to VBA, and I'm trying to..." along with "Here's the code I have so far" goes a lot further than "Would someone write a macro for me to do..."

I think you'll find these guidelines apply to just about any forum in which there are less-experienced people asking questions to more-experienced people.
 
Finethread,

Have you tried the macro I suggested? From your initial response to my post I believe you have, but I wanted to make sure.

I don't think it's an overly cumbersome process to run a macro to do what you want (if I've correctly interpreted what you want to do, this method accomplishes it exactly). It may not be the most elegant, automated method but it meets the following criteria:

1) It works
2) It's quick
3) It's free

In this particular instance, you can have all three.....
 
Just to continue this line of thought, an automatic method can be made in a save macro. That macro (when used to save your drawing) would look at the part's desc custom property (same as the save dialog description), then grab that value and apply it to the drawing, then saves the drawing.

The macro would insure the two desc's values are the same at the time when the drawing is saved. This is automatic, but it still isn't real time, which is what I'm sensing you feel you need. Let us know.



Matt
CAD Engineer/ECN Analyst
Silicon Valley, CA
 
Fcsuper, automatic is just peachy.

It's not that I need one way or the other....I'm just trying to make things easy for users and to eliminate redundancies. If I had access to this macro, I would offer it to my users as an alternative to cutting and pasting.

Thanks

Stopped by your site.....great resource.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor