2011-08-24 05:11 PM - last edited on 2023-08-03 09:41 AM by Doreena Deng
API_WorkspaceInfo workspaceInfo; API_StoryInfo storyInfo; API_ProjectInfo projectInfo; GSErrCode err; Int32 ind; err = ACAPI_Environment (APIEnv_ProjectID, &projectInfo, NULL); err = ACAPI_Environment (APIEnv_UserWorkspaceID, &workspaceInfo, &projectInfo.userId); BNZeroMemory (&storyInfo, sizeof (API_StoryInfo)); ACAPI_Environment (APIEnv_GetStorySettingsID, &storyInfo, NULL); ind = (*workspaceInfo.stories); //ACAPI_WriteReport("", ); ACAPI_WriteReport( " "+(*storyInfo.data)[storyInfo.firstStory].floorId, true);When I run the built add-on, through AC, the program crushes (bug report).
2011-08-27 04:47 PM
zanzibar wrote:I've answered your question about retrieving storey information in another post. Just a few comments about your code:
Hello,
Im trying to develop something, and first of all need to access floor id.
I tried this code: ...etc... When I run the built add-on, through AC, the program crushes (bug report).
Is there another way to access this kind of information? (story information)
2011-08-27 04:54 PM
2011-08-27 05:20 PM
zanzibar wrote:I think you need to take a course in C/C++ (or study the subject). A C programmer would not expect to be able to write:
Well, I guess that its because im not used to this platform.
I actually used the BNZeroMemory function because I saw that the example scripts use it, and I even tried to understand what it means, but it didnt work well. do u have any idea how to explain me that in a simpler way?
And I didnt really catch what u meant in par 4.
Thanks for ur attention!
"1 + 1 = " + 2;That's something you might do with BASIC.
ind = (*workspaceInfo.stories);Where does the subscript value
2011-08-27 07:40 PM
2011-08-28 10:21 AM
zanzibar wrote:I assumed so, but it would have been very helpful if you had left the loop in your sample code. Loops and subscript variables are common sources of hanging/crashing problems. I'm also assuming your loop begins just after the call to
The "i" value comes from a loop that runs this function for each floor, I assumed that 0,1,2 and so on are floor indexes.
2011-08-28 03:02 PM