License Delivery maintenance is expected to occur on Saturday, November 30, between 8 AM and 11 AM CET. This may cause a short 3-hours outage in which license-related tasks: license key upload, download, update, SSA validation, access to the license pool and Graphisoft ID authentication may not function properly. We apologize for any inconvenience.
Archicad C++ API
About Archicad add-on development using the C++ API.

What error is -2130312307?

LeeJaeYoung
Virtuoso

LeeJaeYoung_0-1675178670141.png

 

What error is -2130312307?

I added a menu in element_test and an error occurred, so I modified the existing menu, but the same error occurs.

This is the ac26 version.

 

 

GSErrCode __ACENV_CALL ElementsHotlink (const API_MenuParams *menuParams)
{
GSErrCode err = NoError;
switch (menuParams->menuItemRef.itemIndex) {
case 1: Do_CreateBeam(); break;
//case 1: err = Do_CreateHotlink (); break;
case 2: err = Do_ChangeHotlink (); break;
case 3: err = Do_UpdateHotlink (); break;
case 4: err = Do_DeleteHotlink (); break;
case 5: err = Do_BreakHotlink (); break;
case 6: Do_ListHotlinks (); break;
case 7: Do_ListHotlinkProxyElements (); break;
case 8: Do_ModifiyHotlinkNode (); break;

default: break;
}

return err;
} /* ElementsHotlink */
AC27 on window 11
4 REPLIES 4
Miha Nahtigal
Advocate

Are you calling your create element function inside ACAPI_CallUndoableCommand block?

BIMquants.comBETA - Quantities and Costs Estimation in Archicad - BETA testers needed.

Archicad Error Codes 

 

APIERR_NEEDSUNDOSCOPE -2130312307 8106038D The called command should be encapsulated in a ACAPI_CallUndoableCommand scope.
Gerry

Windows 11 - Visual Studio 2022; ArchiCAD 27

I found out about my problem and fixed it.
Thank you very much.

And
If you know how ac26 develops api with visual studio 2019, can you explain in detail?
I can't make it with cmake
I am studying while adding in element_test.
I also got a template file, but this is a question because I don't know where and how to install it and how to run it.

 

Re: How to start api (c++) in 26? - Graphisoft Community

AC27 on window 11
akiss
Graphisoft
Graphisoft

Hi

The best way to start developing Archicad AddOns is to follow the steps in Getting started with Archicad Add-Ons.

 

Best regards,

András