Quantcast
Channel: NX Journaling - Journaling / NXOpen API
Viewing all articles
Browse latest Browse all 783

Updating Point Coordinates in NX With New XYZ Values in JAVA

$
0
0

I am in need of help with a JAVA program.
I did not write this program and could use some help to update one of the 3D points.
I have a program that imports part geometry (A) in another part (B) locating it on 3 points.
Point data is collected per a JAVA program from picking points on a model in an NX part when prompted.
Point1 values are correctly imported into Pdata1 while running the program.
Point2 values are correctly imported into pdata2 while running the program.
Point3 values are correctly created for pdata3 while running the program but are not applied to the point.
The program creates a new point P20 in Expressions and puts the point at 0 on the end of a line.
I need code to update point P20 with the coordinates collected for Pdata3.
It looks like the easiest way to correct the problem will be to update the coordinates at the end of the program by telling P20 to be a 3D point using Point3d(pdata3[0], pdata3[1], pdata3[2]).
Keep in mind the coordinates are collected and not applied in the program.
Can someone please help me write some code that will update point P20 with the coordinates collected for Pdata3 at the end of the program?
The program uses expressions to apply the coordinates.
See the existing code:

nxopen.SelectionIntentRule [] rules1 = new nxopen.SelectionIntentRule[1];
rules1[0] = edgeChainRule1;
nxopen.NXObject nullNXOpen_NXObject = null;
nxopen.Point3d helpPoint1 = new nxopen.Point3d(pdata3[0], pdata3[1], pdata3[2]);
section2.addToSection(rules1, edge1, nullNXOpen_NXObject, nullNXOpen_NXObject, helpPoint1, nxopen.Section.Mode.EDIT, false);


Viewing all articles
Browse latest Browse all 783

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>