• Industries
  • Products
  • Buy
  • Services & Support
  • Communities
  • Discussion Groups

    Autodesk Inventor Engineer-to-Order

    Reply
    Mentor
    bsee1
    Posts: 172
    Registered: ‎11-14-2011
    Accepted Solution

    Intent api get the refchain of a Component Occurrence object

    170 Views, 1 Replies
    08-09-2012 06:15 AM

    I'm building a user interface, and I'd like to allow the user to click on the part they want to add a child to.  When they click on a part, it returns a component occurrence.  How can I get the refchain of this ComponentOccurrence object?

     

    The childName is NOT the same as the displayName, so I cannot use the display name.

     

    Thank you,

    Brandon

    *****************************
    Win7 x64 - 16gb ram
    i7 3610qm
    FirePro M4000

    Inventor 2013
    ETO 6.1
    Please use plain text.
    Employee
    AlexKorzun
    Posts: 71
    Registered: ‎11-10-2008

    Re: Intent api get the refchain of a Component Occurrence object

    08-09-2012 12:39 PM in reply to: bsee1

    Hi

     

    HostAPI has a method that returns a ref string from the Inventor object:

     

    string refChain = Autodesk.Intent.IntentAPI.Instance.HostAPI.HostApplication.RefChainFromHostObject( occ)

     

    You may wish to feed the result into RefChain class constructor for further analysis.

     

    Thank you,

    Alex Korzun
    Principal Engineer
    Inventor Engineer-to-Order
    Please use plain text.