How to run automaticaly a GRIP program just after opened a part file ?
How to run automaticaly a GRIP program just after opened a part file ?
(OP)
Hi,
I would like to run automatically a GRIP program just after opened a part file.
What are the all the steps?
Is it possible to have a sample!
Thanks a lot
SuperQuark
I would like to run automatically a GRIP program just after opened a part file.
What are the all the steps?
Is it possible to have a sample!
Thanks a lot
SuperQuark





RE: How to run automaticaly a GRIP program just after opened a part file ?
You may be able to do it with UGMenu customization and put the action of running the GRIP program after the Open command.
Another method would be to usee a user exit and use your GRIP program to both open the file and run your customizations after the file is opened.
"Wildfires are dangerous, hard to control, and economically catastrophic."
Ben Loosli
RE: How to run automaticaly a GRIP program just after opened a part file ?
Thanks for your reply . . .
I need to open some part files and I would like that attributes defined in the part will be set by the GRIP program.
So, I just want to click on the prt file to open it, and the GRIP program must be stated automaticaly after it was displayed.
In this way each time I open the part file the attributes were updated . . .
Could you explain me how I could make it ?
Many thanks in advance.
SuperQuark
RE: How to run automaticaly a GRIP program just after opened a part file ?
John R. Baker, P.E.
Product 'Evangelist'
Product Engineering Software
Siemens PLM Software Inc.
Industry Sector
Cypress, CA
Siemens PLM:
UG/NX Museum:
To an Engineer, the glass is twice as big as it needs to be.
RE: How to run automaticaly a GRIP program just after opened a part file ?
At this time I work with NX6 . . .
Here some explanations that I really would like to make:
I want to extract strings from the drawing sheet attribute <W@$SH_PART_NAME>
Sample:
When I create a note with <W@$SH_PART_NAME>, the result is Cover_1234.prt
So I need 2 attributes (or expression) strings:
First one is : Title = Name ; Value = Cover
Second one is : Title = Number ; Value = 1234
How can I extract substring from <W@$SH_PART_NAME>?
Thanks
SuperQuark
RE: How to run automaticaly a GRIP program just after opened a part file ?
Long_note = 'This is a long note'
sht_note = substr(long_note,11,9)
sht_note will be 'long note'
The substr command takes your string, the start position and # of charcaters and returns a portion of your string.
"Wildfires are dangerous, hard to control, and economically catastrophic."
Ben Loosli
RE: How to run automaticaly a GRIP program just after opened a part file ?
I know the substr function in GRIP, but my question was how do you use it whith <W@$SH_PART_NAME> into NX as an attribute or as an expression ?
I don't find it, so it was for this reason that I thought to write a GRIP program.
I hope it is clear now . . .
Many thanks
SuperQuark
RE: How to run automaticaly a GRIP program just after opened a part file ?
What are you planning on doing with the sheet name attributes?
"Wildfires are dangerous, hard to control, and economically catastrophic."
Ben Loosli
RE: How to run automaticaly a GRIP program just after opened a part file ?
I would like to extract the string COVER and the string 1234 and put them into attributes variables.
So, the result will be :
Attribute1 = COVER
Attribute2 = 1234
Then I will use it to fill in my drawing box . . .
TITLE = COVER (Attribute1)
NUMBER = 1234 (Attribute2)
SuperQuark
RE: How to run automaticaly a GRIP program just after opened a part file ?
Search the string for the '-', then extract the beginning and assign it to the Sheet name attribute.
Uste the rest of the string for your partname attribute assigned in your format.
"Wildfires are dangerous, hard to control, and economically catastrophic."
Ben Loosli