Dear Development,
For programming a good boundingbox is needed sometimes. But according to this thread that's not possible with Inventor.
So with this code I think it should be possible to have an exact boundingbox:
boundingboxXmin = _Doc.ComponentDefinition.WorkPlanes.AddByPlaneAndOffset(_Doc.ComponentDefinition.WorkPlanes.Item(1), baseBody.RangeBox.MinPoint.X)
boundingboxXmax = _Doc.ComponentDefinition.WorkPlanes.AddByPlaneAndOffset(_Doc.ComponentDefinition.WorkPlanes.Item(1), baseBody.RangeBox.MaxPoint.X)
boundingboxYmin = _Doc.ComponentDefinition.WorkPlanes.AddByPlaneAndOffset(_Doc.ComponentDefinition.WorkPlanes.Item(2), baseBody.RangeBox.MinPoint.Y)
boundingboxYmax = _Doc.ComponentDefinition.WorkPlanes.AddByPlaneAndOffset(_Doc.ComponentDefinition.WorkPlanes.Item(2), baseBody.RangeBox.MaxPoint.Y)
And not something like this:

Regards,
David