Forum Migration Notice
Update (2026-01-21): The user forums are now in read-only mode pending the data migration.

Update (2026-01-12): The user forums will be put into read-only mode on the 21st of January, 00:00 CET, to prepare for the data migration.

We're transitioning to a more modern community platform by beginning of next year. Learn about the upcoming changes and what to expect.

'Object is part of a project' debug error

When running my add-in I get the error message 'ArgumentException is unhandled: Object is part of a project' in the Visual C# debugger when
[CODE]myPart.Bodies.Add(myWire);[/CODE] executes.
Can anyone explain what this message means?

Thanks,

Kevin

Comments


  • An object cannot have two parents. You must make sure myWire is "orphaned" before you add it to a part.

    BTW, API questions should go in the "Developer Tools" forum.
    Johannes Weiman2010-05-07 10:55:53
    Johannes Weiman
    Software Engineer
    ABB Robotics
  • Kevin
    Kevin ✭✭
    Thanks Johannes.

    Kevin