We value your input!
Please participate in Archicad 28 Home Screen and Tooltips/Quick Tutorials survey

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

[API] breakin long time operation from API

Anonymous
Not applicable
Hello!

I have long time working algorithm, and I start it by pressing button on dialog box. Unfortunately I cant brake it. ArchiCAD doesn't process any messages and i have to wait until the end. I've try to put algorithm in thread, but ArchiCAD crashes when I call the ACAPI_LibPart_Register function. Do You know any Check_if_there_is_message_to_process function?

Thanks!
Maciek
2 REPLIES 2
Ralph Wessel
Mentor
bamboos wrote:
I have long time working algorithm, and I start it by pressing button on dialog box. Unfortunately I cant brake it. ArchiCAD doesn't process any messages and i have to wait until the end. I've try to put algorithm in thread, but ArchiCAD crashes when I call the ACAPI_LibPart_Register function. Do You know any Check_if_there_is_message_to_process function?
Are you looking for something to display a progress meter with a "Cancel" button? If so, take a look at "APIIo_InitProcessWindowID" and associated commands (under "ACAPI_Interface").
Ralph Wessel BArch
Software Engineer Speckle Systems
Anonymous
Not applicable
Yes! That's it.
Thanks a lot.

Maciek