Submitted by psi-cad on Mon, 03/15/2021 - 06:50
Forums:
Hi,
In NX12, there is a bug with feature dimension that doesn't update. So I try to create an NXOpen programm to edit all dimensions.
I started with the following lines but then I don't see how to get all parents to be able to insert the journal recorded interactivly.
For Each tempFeat As Features.Feature In workPart.Features
If TypeOf (tempFeat) Is MeasureMaster Then
lw.WriteLine("Measure name: " & tempFeat.GetFeatureName)
End If
Next
Thanks a lot
Regards
Didier
re: edit features
Are you trying to get the parent features of a given feature? If so, you can use the .GetParents method, which will return an array of features that are parents of the given feature.
I'm not familiar with the bug that you mentioned; what exactly are you trying to accomplish?
Hi,
Hi,
Thanks for your answer
Find herewith a part to explain the bug
Open the part
Have a look at the content and associative points and datums
Change user expression move_face from 1 to 2
Check that the point and datums are not correct
Apply filter dimensions on the ANT
Then edit all dimensions one by one
Then check that points and datums are correct now
This bug is corrected in NX1953, but my customer stay in NX12 at the moment
So, I need an NXOpen programm to edit all dimensions
I am not an NXOpen expert, so could you help me to use .getparents
Thanks a lot
Regards
Didier
re: edit features
It sounds like you might need to force a model update; the .DoUpdate method might help here. If you search the site, there are several journals where it is used.
If .DoUpdate doesn't help in your case, try (in interactive NX) to force an update with "update for external change". If this works, there is a way to force such an update in a journal, but it is a bit trickier than using .DoUpdate.
Oops, I forgotten to share my
Oops, I forgotten to share my part, but how to do on the forum ?
re: upload part
The site doesn't currently allow file uploads.
Hi,
Hi,
I had already tested "Update for External change" and it doesn't work in my case
I have just tried .DoUpdate Method and it doesnt work with the following lines
lw.WriteLine("Update")
Dim markId2 As Session.UndoMarkId
markId2 = theSession.SetUndoMark(Session.MarkVisibility.Invisible, "Update")
Dim nErrs1 As Integer
nErrs1 = theSession.UpdateManager.DoUpdate(markId2)
I am going to ceate a post in Eng Tips, by this way, you can have a look at my part.
Regards
Didier
re: update features
{reminder for myself}
eng-tips post (with file upload) for reference:
https://www.eng-tips.com/viewthread.cfm?qid=481003
Update?
Hi,
I am also having this issue with NX1973.
I cannot seem to update the measurement after it is created.
I have tried the DoUpdate method, but it does not seem to help.
The MeasureMaster has no type of "commit", so I don't see how you create the measurement.
Cheers
Philip
IT Solution Specialist at Siemens in Nuremberg
Mechanical Engineer from Georgia Tech