Current Window Title

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2021-07-30
06:26 AM
- last edited on
2021-09-14
09:24 AM
by
Noemi Balogh
2021-07-30
06:26 AM
I an trying to get the current window title (Windows 10 -- Archicad 25) , current floor plan. Following the example i used ACAPI_Database(APIDb_GetCurrentWindowID,...) To retrieve windowInfo but the documentation states that the title info is not filled in windowInfo and that one must then use ACAPI_Database(APIDb_GetDatabaseInfoID, ...).
NOLUCK -- the title info is blank
NOLUCK -- the title info is blank
API_WindowInfo windowInfo; BNZeroMemory(&windowInfo, sizeof(API_WindowInfo)); //GS::Array<API_DatabaseUnId> dbases; GS::GSErrCode err = ACAPI_Database(APIDb_GetCurrentWindowID, &windowInfo, nullptr); if (err) { ACAPI_WriteReport(" Error - %s", true, ErrID_To_Name(err)); } else { API_DatabaseInfo dbPars = {}; dbPars.databaseUnId = windowInfo.databaseUnId; ACAPI_Database(APIDb_GetDatabaseInfoID, &dbPars, nullptr); char msg[1024]; sprintf(msg, " success index - %d name - %s", dbPars.index, dbPars.name); ACAPI_WriteReport("Title %s", true, msg); }Thanks
Gerry
Windows 11 - Visual Studio 2022; ArchiCAD 27
Windows 11 - Visual Studio 2022; ArchiCAD 27
Labels:
- Labels:
-
Add-On (C++)
0 REPLIES 0