Hi everyone.
I tryed to find any similar question, but it doesnt succes.
I cad model any section in ABD Connect Edition using VBA and STF library (AECOSimBuildingDesigner Structural 9.1 Library). The code uder helps model sections
But now i need to model slab in ABD. I am going to use STFSolid from the same library. Anybody have code for this aim. I mean create a solid in ABD using VBA.
Hi,
Please check whether the following code helps:
Function CreateASlab(aX As Double, aY As Double, aZ As Double, bX As Double, bY As Double, bZ As Double, cX As Double, cY As Double, cZ As Double, dX As Double, _ dY As Double, dZ As Double, Thickness As Double) 'Set a vertex list array of Point3d to save the corners of the slab Dim vertexlist(0 To 3) As Point3d vertexlist(0).X = aX vertexlist(0).Y = aY vertexlist(0).Z = aZ vertexlist(1).X = bX vertexlist(1).Y = bY vertexlist(1).Z = bZ vertexlist(2).X = cX vertexlist(2).Y = cY vertexlist(2).Z = cZ vertexlist(3).X = dX vertexlist(3).Y = dY vertexlist(3).Z = dZ 'Create variable with datatype STFSolid for the slab Dim mySlab As STFSolid 'Initialize the variable Set mySlab = New STFSolidList 'Assign further porperties for the slab to be created. This list is not exhaustive mySlab.SetFaceVertices vertexlist() mySlab.SetThickness Thickness mySlab.SetPartFamily "S-FloorSlabs" 'Change this to suit your requirement mySlab.SetPartName "S_BSUK_Slabs" 'Change this to suit your requirement 'Create and save the slab mySlab.CreateTFFormRecipeList mySlab.Save True End Function Sub bbbbb() CreateASlab 0, 0, 0, 1500, 0, 0, 1500, 1500, 0, 0, 1500, 0, 125 'Pass the vertices and thickness to the function CreateASlab to create the slab End Sub
Regards,
Satadal
Answer Verified By: Владислав Ахунджанов
Thanks! It works.