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

WriteReport API function, Where is the prompt on macOS X

Anonymous
Not applicable
<Re-Post>
These look like simple "DUHHH"- blonde questions...

Building and running the Library Part Example (with my dev ID) I noticed that the WriteReport doesn't seem to print into the Report Window or anywhere I could find.

On the Windows side I found the prompt messages, but on the mac side I couldn't find a way to view the prompt messages. Maybe there is no way to have them on the MAC?
3 REPLIES 3
Karl Ottenstein
Moderator
The WriteReport entries show up in the session report for me (attached).

The ClickAnElem prompt shows up in the status bar, as it should, and the WriteReport_Alert (WriteReport with true as 2nd arg) brings up a modal alert dialog for me in that example file, as it should.

Karl
Picture 3.png
One of the forum moderators
AC 28 USA and earlier   •   macOS Sonoma 14.7.1, MacBook Pro M2 Max 12CPU/30GPU cores, 32GB
Karl Ottenstein
Moderator
Correction. WriteReport_Alert (which calls ACAPI_WriteReport with 'true' as the second param) displays both the dialog as well as makes the report entry for me (Mac).

WriteReport, which is supposed to make an entry in the session report, but NOT bring up a dialog (calls ACAPI_WriteReport with false as 2nd arg), enters nothing into the report.

One of us will have to test ACAPI_WriteReport directly to see if the issue is the Mac API, or the formatting of the buffer by the code in the example files WriteReport function...

Yes... I just called ACAPI_WriteReport directly, and the text was printed into the session report as it should. So, something seems amiss with the WriteReport routine in the APICommon.c file.

Karl
One of the forum moderators
AC 28 USA and earlier   •   macOS Sonoma 14.7.1, MacBook Pro M2 Max 12CPU/30GPU cores, 32GB
Anonymous
Not applicable
"DUHHH" on the mac the Statusbar is a separate Palette. Indeed.

Interesting: changed WriteReport to WriteReport_Alert, and (Release build on XCode 3.1.2): it indeed writes into the Report window, but I saw no alert dialog to pop up.
Poking around in APICommon.c WriteReport has if mac conditional as well as usedebugwindow conditional too. So probably somewhere deep one of the branching codetree misses something. Will see on Windows. At this moment this behavior is perfect for me