# How can I obtain and set the parting gap of the component through the API

**URL:** https://forum.dynamobim.com/t/how-can-i-obtain-and-set-the-parting-gap-of-the-component-through-the-api/106312
**Category:** Developers
**Tags:** revit, dynamo
**Created:** [December 4, 2024, 9:56am UTC](https://forum.dynamobim.com/t/how-can-i-obtain-and-set-the-parting-gap-of-the-component-through-the-api/106312 "2024-12-04T09:56:54Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Hongyan.D](https://avatars.discourse-cdn.com/v4/letter/h/76d3ee/32.png) [@Hongyan.D](https://forum.dynamobim.com/u/Hongyan.D)
#### Post date: [December 4, 2024, 9:56am UTC](https://forum.dynamobim.com/t/how-can-i-obtain-and-set-the-parting-gap-of-the-component-through-the-api/106312/1 "2024-12-04T09:56:54Z")

</div>

How can I obtain and set the parting gap of the component through the API or dynamo

---

<div class="post-metadata">

### Author: ![Draxl\_Andreas](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/draxl_andreas/32/145744_2.png) [@Draxl\_Andreas](https://forum.dynamobim.com/u/Draxl_Andreas)
#### Post date: [December 4, 2024, 11:44am UTC](https://forum.dynamobim.com/t/how-can-i-obtain-and-set-the-parting-gap-of-the-component-through-the-api/106312/2 "2024-12-04T11:44:53Z")

</div>

@Hongyan.D

can you explain it a bit more. share some screenshots… 😉

---

<div class="post-metadata">

### Author: ![Hongyan.D](https://avatars.discourse-cdn.com/v4/letter/h/76d3ee/32.png) [@Hongyan.D](https://forum.dynamobim.com/u/Hongyan.D)
#### Post date: [December 5, 2024, 5:14am UTC](https://forum.dynamobim.com/t/how-can-i-obtain-and-set-the-parting-gap-of-the-component-through-the-api/106312/3 "2024-12-05T05:14:58Z")

</div>

part divideParts Gap

 ![image](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/9/6/9658e78dc4119f85bf971bd344e711808b8c4524.png)

---

<div class="post-metadata">

### Author: ![GavinNicholls](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/gavinnicholls/32/190442_2.png) [@GavinNicholls](https://forum.dynamobim.com/u/GavinNicholls)
#### Post date: [December 5, 2024, 7:39am UTC](https://forum.dynamobim.com/t/how-can-i-obtain-and-set-the-parting-gap-of-the-component-through-the-api/106312/4 "2024-12-05T07:39:24Z")

</div>

Assume you can get that element, that is a builtinparameter:

> **[BuiltInParameter Enumeration](https://www.revitapidocs.com/2022/fb011c91-be7e-f737-28c7-3f1e1917a0e0.htm)**
>
> Online Documentation for Autodesk's Revit API: 2015, 2016, 2017, 2017.1, 2018

Divisions have a builtincategory, so an element collector could get them, but they might not have much in the way of class/API beyond that based on my searching:

> **[BuiltInCategory Enumeration](https://www.revitapidocs.com/2022/ba1c5b30-242f-5fdc-8ea9-ec3b61e6e722.htm)**
>
> Online Documentation for Autodesk's Revit API: 2015, 2016, 2017, 2017.1, 2018

---

<div class="post-metadata">

### Author: ![Hongyan.D](https://avatars.discourse-cdn.com/v4/letter/h/76d3ee/32.png) [@Hongyan.D](https://forum.dynamobim.com/u/Hongyan.D)
#### Post date: [December 5, 2024, 9:24am UTC](https://forum.dynamobim.com/t/how-can-i-obtain-and-set-the-parting-gap-of-the-component-through-the-api/106312/5 "2024-12-05T09:24:12Z")

</div>

![2024-12-05_17-20-06](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/9/b/9bd908341264d9fd39ecc2e6ae6547ea088c1828.png)  
I tried to use RIR to implement this feature, but it prompted me that “Parameter ‘Gap’ is not defined on ‘Element’”. I found the API named PARTMAKER\_PARAM\_DIVISION\_GAP, but I’m not sure if it can be implemented using C#.

---

<div class="post-metadata">

### Author: ![GavinNicholls](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/gavinnicholls/32/190442_2.png) [@GavinNicholls](https://forum.dynamobim.com/u/GavinNicholls)
#### Post date: [December 5, 2024, 10:05am UTC](https://forum.dynamobim.com/t/how-can-i-obtain-and-set-the-parting-gap-of-the-component-through-the-api/106312/6 "2024-12-05T10:05:37Z")

</div>

It looks like the element is divisions as oppose to the geometric element. Try collecting all elements of that category instead and inspect its parameters to see if there’s a way to get it back to its relater elements.
