2024-05-30 08:32 AM - last edited on 2024-06-06 04:57 PM by Laszlo Nagy
What is API_Neig?
I encountered the term API_Neig in the MEP Test example, where it is used for selecting an MEP element. Can someone explain what API_Neig represents and how it is used in the context of MEP elements?
Extracting Polyline Information for All Routing Elements in the Model
I want to extract the Polyline information for all Routing Elements from the entire model, not just from a specific selection. Here’s the workflow I’m using:
However, I’m unable to get any coordinates using this method. The same workflow successfully retrieves the polyline when a specific routing element is selected. What could be the issue with extracting polyline data for all routing elements in the model?
2024-05-30 08:39 AM
@Viktor Kindly help
2024-05-30 08:42 AM
2024-05-31 09:52 AM
API_Neig is primarily concerned with element selection. It carries element identifiers so the element can be loaded, e.g. with ACAPI_Element_Get, but also contains information about how/where the element was selected, e.g. if the user selected a hole in a slab, the API_Neig structure would identify that a slab was selected and carry enough data to identify the selected hole. This means that any add-on looking at the user selection will use this structure, including MEP add-ons.
2024-05-31 10:01 AM
If you want to find all elements of some type rather than just the selected elements, take a look at ACAPI_Element_GetElemList. This allows you to retrieve an array of elements from anywhere (whether selected or not).
2024-05-31 12:14 PM
Hi Ralph,
Thank you for your previous response. I'm currently working on extracting polyline data for all MEP elements in my model. Here's the workflow I'm implementing:
Retrieve All Elements:
Filter for MEP Elements:
Extract Polyline Data from Routing Elements:
Although I've implemented this workflow, I'm not getting any results. Can you please help me identify what might be going wrong or suggest any improvements?
Thank you!
2024-05-31 12:15 PM
2024-05-31 01:55 PM
Can you clarify what you mean by "not getting any results"? At what point in the 3 steps you described does the process seem to fail? For example, is the process correctly finding MEP elements? If so, how are you trying to get the required information from them (and what happens)?
2024-06-03 06:52 AM
In the third step, I am not able to obtain any polyline data; First two steps succeed. When I use the following line
2024-06-03 11:41 AM