Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

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

GRIP: INTSEC/ ...help/example needed

Status
Not open for further replies.

Shadowspawn

Aerospace
Joined
Sep 23, 2004
Messages
259
Location
US
Folks,

It's been a while, and I'm apparently a bit rusty. I'm trying to write a grip that will develop a series of planes (all on z-axis), and generate cross-sections of a user picked sheet body (via ident/). I'm generating the planes, and picking the sheet body ok... but am failing when trying to use the INTSEC/.

<code>
ENTITY/PL(200),$ $$ ARRAY FOR PLANES
SHEET1,$ $$ SHEET FOR SECTIONING
SECTLINES(100) $$ ARRAY FOR SECTION LINES
...
DO/L41:,J,1,100,1
SECTLINES(J)=INTSEC/SHEET1,WITH,PL(J)
...
</code>

routine compiles ok...
runtime error: "attempt to use an object variable to which no object has been assigned."

Ideas? Help is much appreciated and TIA.

Regards,
SS

CAD should pay for itself, shouldn't it?
 
John,
I believe so (but could be wrong...). I'm pulling an expression from NX for the shrink value..
<code>
$$ pulling shrink value from NX part exp
$$ ...actual value = 1.012
SL=REGF('SHRINKZ')
$$ M== ht of sect value * shrink value
M=(Z(I)*SL)
$$ create plane for cutting section on AF
PL(I)=PLANE/XYPLAN,M
</code>

The planes are created at the correct heights...

Regards,
SS

CAD should pay for itself, shouldn't it?
 
I suspect the plane sub may be starting at value higher than one. The following runs ok.

$$ section plane generator

$$<code>
NUMBER/R
ENTITY/PL(200) $$ ARRAY FOR PLANES
SHEET1,$ SHEET FOR SECTIONING
SECTLINES(100) $$ ARRAY FOR SECTION LINES
$$...

DO/L40:,J,1,100
PL(J)=PLANE/XYPLAN,.1*J
L40:

IDENT/'SELECT SURFACE TO INTERSECT',SHEET1,R
DO/L41:,J,1,100
SECTLINES(J)=INTSEC/SHEET1,WITH,PL(J)
L41:
$$...
$$</code>
HALT
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top