Jump to content
  • 0

Ver very simple script in 11.5


Michael Gilbert

Question

I have some old drawings from way back done in 11.5.

Walls have different thicknesses but all have a cavity.

Have been messing around for hours with no success. (Have no time to delve into scripting except about every other year!)

Can anyone suggest a VS that selects all walls - below is my attempt:

PROCEDURE RemoveCavitiesForObject(hObject : HANDLE);

BEGIN
Select(Obj(INSYMBOL (T=WALL)));
END;

PROCEDURE DeleteCavitiesInObjects;
VAR
hObject : HANDLE;
BEGIN
  { Obtain handles of the objects you want to target }

hObject := GetCustomObject('INSYMBOL (T-WALL');

  { Call the RemoveCavitiesForObject procedure for each object }

  RemoveCavitiesForObject(hObject);
END;

RUN(DeleteCavitiesInObjects);

Link to comment

4 answers to this question

Recommended Posts

  • 0
2 hours ago, Michael Gilbert said:

I thought this bit - hObject := GetCustomObject('INSYMBOL (T-WALL'); would select the walls.

That is only going to select a single wall.  And I think you need an "&" between them. I recommend you use the Criteria Builder to generate the criteria.

 

You probably also want to look at ForEachObject. You can put the criteria there once and it will call a sub-procedure you define once for every object the criteria selects.

 

 

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...