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!

Automatic Text Updates

Status
Not open for further replies.

redwingfan01

Automotive
Jan 6, 2009
30
0
0
US
Hello All,
The company I work for is trying to make a jump from nx3 to nx6 and we would like to carry over most of our ‘starter’ or ‘seed’ files to nx6.

Our seed files have various pieces of info in them that is used during the making of prints for the shop floor. This info on blocks and pins and angles and other things are in the form of attributes in string or reference format that automatically updates as we change parameters on the solids. Some examples are size, material, detail number, job number.

On our current print borders the text in the title block is written as <W!126473@MATERIAL> as an example (the 126473 appears to be rather random or maybe not I’m not sure). When I place my borders in nx6 the number between the ‘!’ and the ‘@’ changes to 0 or sometimes becomes a totally different number, which isn’t the correct number for my seed files in nx6. I can correct the number by going - Right Click Text > edit text > Select ‘Relationsships’ > Insert Object Attribute > Select the Attribute > Close. Then I have the attribute in my title block and all is good.

I tried to write a macro to go through this process for the 6 pieces of text that are goobered, but as soon as I go to a new file the macro crashes because the number has changed again.

The borders are placed with a macro that imports a part file with the border/title block/text in nx3 and that macro still works in nx6, so we want to continue to use it. We’ve done this instead of patterns because in drafting we have views with dimensions already on them and with a pattern it appears we have to put all the dimension back on.

So my questions are:
1. How do I create automatic text in a border file that will update to attributes that I have on a solid body?
2. Is there a way to make a pattern file that can be placed on a sheet already containing views or will it always create a new sheet?
3. Any advice of what others do?


The person that set up the nx3 stuff is no longer with the company, left 1 ½ years ago for some reason unknown. He did however create a user interface (hope that is right) that puts the attributes on any newly created solids not in a seed file. Our main seed files have the 11x17 border already in them and that info updates just fine.

Thank you

Scott V
The person stuck trying to figure things out.
 
Replies continue below

Recommended for you

Hi redwing,

I can't answer your question but i'd just like to chime in and say "me too". i'm currently in the process of creating some templates etc and i'm trying to set it up in this manner and i can't seem to get it to work as expected with linking Attributes to Title Block text fields and Master Model properties to TB fields (but no doubt i'm missing somethings as i'm learning in the process as i don't use NX full time).
 
Hi Scott,

Why not using Master Model Templates for your drawings?
As I can see in your description you template has also been set as an Master Model, this I see because it ads a number to the Fields,

You can easily add your Templates to the "File New", and have your Fileds filled in from the Part Attributes.

Any more information you can find in this Thread (Very Helpfull when setting up Templates):

 
I guess the simple answer is because I'm using what was set up by a former employee and is what the engineering manager wants us to use.

I however am not opposed to change if it works. I'll look into the master model templates and take a look at your link (thank you) and see if i can get that to work as desired.

I think as long as everything updates our detail prints and reports for our BoM I really don't care what the process of getting there is.

Thank you
 
hello pdwispe,

Well I've done everything that john said to do in the thread you linked and can't get the templates to work as described.

I also can't figure out how to add my templates to the FILE -> NEW tab or create a new Tab. John mentioned that it was discussed in previous threads but I've been unable to locate them and the help documentation doesn't seem to work because it wants me to run a .bat file that isn't doing anything.

I can get my templates to show up in the side bar, but the text doesn't update when I place the sheet. When I made my first template attempt I was able to select my attributes, now however NO attributes show up when I have 'component' selected while trying to redo the process.

At a loss as to where I'm making a wrong turn.

Any help would be appreciated

 
Hello redwingfan,

are you a single user or do you need to customise things for a group?

I will explain how to set up the templates for a single user, then we can have an update for a group...

First you will need to copy your template(s) to the {UGII_BASE_DIR}\UGII\templates folder and you have to open with notepad/wordpad the ugs_drawing_templates.pax file and you can edit/add this

<PaletteEntry id="d1">
<References/>
<Presentation name="YOUR TEMPLATE (FOR EXAMPLE A0)" description="YOUR TEMPLATE DESCRIPTION">
<PreviewImage type="UGPart" location="drawing_views_template.jpg"/>
</Presentation>
<ObjectData class="DrawingTemplate">
<TemplateFileType>none</TemplateFileType>
<Filename>YOUR TEMPLATE.prt</Filename>
<Units>YOUR UNITS</Units>
<UsesMasterModel>Yes</UsesMasterModel>
</ObjectData>
</PaletteEntry>

Make sure to have for each template an new id. nr

Have luck,

PS, allways restart UG after editing this .pax file
 
Thank you I got it all working now. Still interested in making my own tab across the top but that really isn't all that important.

again thank you
 
Status
Not open for further replies.
Back
Top