×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

how to determine Xform in "ufs.Wave.CreateLinkedBody" & " ufs.So.CreateXformAssyC

how to determine Xform in "ufs.Wave.CreateLinkedBody" & " ufs.So.CreateXformAssyC

how to determine Xform in "ufs.Wave.CreateLinkedBody" & " ufs.So.CreateXformAssyC

(OP)
hi -

maybe someone here can give me a little (big) help.

I have created a VB journal that can wavelink some selected bodies from any components ,to some other selected components.
every things work fine , but anyway not.

The positions of the linked bodies in the components-part´s is everybody in ABS zero . I need to have them positioned in their position as in the topassembly.

I think the Xform´s are the problem - but I´m not quite sure how to control these Xform´s.

lklo


CODE -->

For inx As Integer = 0 To TargetBody.length - 1
            selobj = TargetBody(inx)
            lw.WriteLine(selobj.NAME) ' output til test
            If ufs.Assem.IsOccurrence(selobj.tag) = True Then
                temp = ufs.Assem.AskPrototypeOfOcc(selobj.tag)
            End If
            ufs.Assem.SetWorkPart(temp) '   skifter workpart


            For inx2 As Integer = 0 To ToolBody.length - 1
                selobj = ToolBody(inx2)
                lw.WriteLine(selobj.NAME)
                '----------------------------
                Dim MyComponent = selobj 'måske ok
                Dim CompPart As Part = MyComponent.Prototype
                Dim LinkedFeat As NXOpen.Tag = NXOpen.Tag.Null
                Dim ObjInPart As NXOpen.Tag = ufs.Assem.Askworkpart()
                Dim ufxform As NXOpen.Tag = NXOpen.Tag.Null'>>>>>>>>>>>>>>>>>>>> problem ???????
                Dim lkxform = CType(NXObjectManager.Get(ufxform), Xform)'>>>>>>> problem ???????

                For Each aBody As Body In compPart.Bodies

                    lw.WriteLine(ObjInPart & " --- ") ' output til test

                    ufs.So.CreateXformAssyCtxt(ObjInPart, MyComponent.Tag, NXOpen.Tag.Null, ufxform)
                    ufs.Wave.CreateLinkedBody(aBody.tag, lkxform, ObjInPart, True, LinkedFeat)
                    ufs.Obj.SetName(LinkedFeat, MyComponent.Name)

                Next
                '-----------------------------
            Next
        Next 

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources