how with api get access to the bodies (as object of 2017 SOLIDWORKS API Help - IBody2 Interface ) under structural member feature (picture below), but without:
a) selection by user
c) other ways where need user interaction or know names for selection
I know possibility to find feature from body by traversing body features, but some SolidWorks features ( like combine bodies) hides other features.
Also there is possibility to get those bodies by getting feature faces, and from faces get bodies (IFeatures::GetFaces, IFeatures::IGetFaces2, IFace2::GetBody, and IFace2::IGetBody). Here i see another issue. Body have many faces, so, i will get same body many times. I will use this option (just more code to filter which bodies are the same in list), but maybe someone knows other way?
P.S. I am using VB.NET