cancel
Showing results for 
Search instead for 
Did you mean: 

udeMoveBuilder error

Solution Partner Pioneer Solution Partner Pioneer
Solution Partner Pioneer

Hi

 

I'm trying to enter a Machine Control sub-operation into a Generic Motion operation via NX Open but getting an error message each time. My code is

 

 

Dim udeMoveBuilder1 As CAM.UdeMoveBuilder = genericMotionControl1.CAMMoveCollection.CreateUdeMoveBuilder(nullCAM_Move)

Dim udeSet1 As CAM.UdeSet = udeMoveBuilder1.UdeSet
Dim ude1 As CAM.Ude = udeSet1.CreateUdeByName("insert")
Dim udeParameter1 As CAM.UdeParameter = ude1.GetParameter("Instruction")
udeParameter1.StringText = "FN 15: PRINT 99"
udeMoveBuilder1.UdeSet.UdeList.Append(ude1)
Dim udeMove1 As CAM.ManualMove = udeMoveBuilder1.Commit()
udeMoveBuilder1.Destroy()

genericMotionControl1.AppendMove(udeMove1)

 

 The error is being reported as occuring on the udeMoveBuilder1.commit line and says 

 

NXOpen.NXEception: Machine Control Event Tag is Null. at NXopen.Builder.Commit

 

I am using NX8.0. I get same error message if a journal the proceedure and then try playing the journal back. Is this just a software bug or am I missing something out. Any help would be great thanks.

 

Cheers

 

Matt

3 REPLIES

Re: udeMoveBuilder error

Honored Contributor
Honored Contributor

Try calling the .Validate method of the builder object before calling the .Commit method. If .Validate returns True and .Commit throws an error, I'd suggest contacting GTAC.

Re: udeMoveBuilder error

Solution Partner Pioneer Solution Partner Pioneer
Solution Partner Pioneer
Thanks for the suggestion cowski1. I included the line udeMoveBuilder1.Validate() before the commit line but now I get the error message

NXOpen.NXException: Machine Control Event tag is null.

I've worked out a work around where I import a new operation with the ude already. Works but not a tidy as you would want.

Cheers

Matt

Re: udeMoveBuilder error

This has been a reported problem. Check out this link:

 

https://solutions.industrysoftware.automation.siemens.com/view.php?sort=desc&file_type=text&q=UDE+vb...

 

However, the better work around for this might be using User Defined Move Type to mimic your UDE, since API for User Defined Move Type works.