Archicad C++ API
About Archicad add-on development using the C++ API.

Creating Polygonal opening on a wall


Hello team,

We are trying to create a polygon-shaped opening through Add-On. We were able to create a square opening but unable to create a polygon-shaped opening. We did some reverse engineering ie. Tried to fetch the element with type OpeningID after drawing one and inspected the element but could not see anything that would define the points of the polygon. Attached is the screenshot of the values that we could observe of the Opening element(there are two screenshots) and the model that we are inspecting. Is it something that has support in Add-On? We also noticed that the field extrusionGeometryData.customBasePolygon is marked as Reserved for future use.


GSErrCode GetOpeningDetails() {
    GSErrCode err = NoError;
    GS::Array<API_Guid> elemList;
    ACAPI_Element_GetElemList (API_OpeningID, &elemList);
    for (const API_Guid& guid : elemList) {
        API_Element element = {};
        API_ElementMemo memo;
        BNZeroMemory (&memo, sizeof (API_ElementMemo));
        element.header.guid = guid;
        err = ACAPI_Element_Get (&element);
        if (err != NoError) {
            std::cout << "Error when trying to get element" << std::endl;
        err = ACAPI_Element_GetMemo(guid, &memo);
        if (err != NoError) {
            std::cout << "Error when trying to get element memo" << std::endl;
    return err;



Didn't find the answer?

Check other topics in this Forum

Back to Forum

Read the latest accepted solutions!

Accepted Solutions

Start a new conversation!