Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations KootK on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

ETABS VBA Code

Status
Not open for further replies.

RAJAVARDHAN

Structural
Apr 14, 2024
2
Hi, I cannot select frames and walls based on section properties in etabs v21 and then delete selected frames and walls. Can anyone suggest to me the code to do it using Excel VBA code?
 
Replies continue below

Recommended for you

Rajavardhan, I would think a combination of getting selected objects, filtering out frames and areas and then testing for material property types would do the trick.

image1_anjvge.png


image2_jcmgwd.png




S&T
 
I have tried it, but nothing happen

ret = SapModel.GetSelected(NumberItems, 2, 0 - Delete - Beam)

Can you please write those few lines only to select and delete it
 
Hi Raj,

I have not coded in VBA before, but the code in C Sharp needs to look a bit different than what you have shown.
C#:
int NumberItems = 0;
int[] ObjectType = null;
string[] ObjectName = null;
_SapModel.SelectObj.GetSelected(ref NumberItems, ref ObjectType, ref ObjectName);



S&T
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor