# EntireX .Net Client Mappings from IDL file (Natural Extract)

**URL:** <https://techcommunity.softwareag.com/t/entirex-net-client-mappings-from-idl-file-natural-extract/233628>\
**Category:** Forum\
**Tags:** Adabas-Natural, Natural, EntireX\
**Created:** [September 13, 2020, 7:38pm UTC](https://techcommunity.softwareag.com/t/entirex-net-client-mappings-from-idl-file-natural-extract/233628 "2020-09-13T19:38:16Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![darrylchetty](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/darrylchetty/32/7685_2.png) [@darrylchetty](https://techcommunity.softwareag.com/u/darrylchetty)\
**Post date:** [September 13, 2020, 7:38pm UTC](https://techcommunity.softwareag.com/t/entirex-net-client-mappings-from-idl-file-natural-extract/233628/1 "2020-09-13T19:38:17Z")

</div>

Hi all

Is it possible to change the mapping of arrays to Lists instead when generating the .net client from the IDL?

I have a scenario where I am getting a list of Bank names and this is being mapped to `string[]` in .Net C# for the client file. The problem is that this list can vary and since this client file is creating the stub to use as ref parameters, I can’t really account for a variable array.

I am currently getting an array of 62 items but initialising the array to say 100 items (to try and cater for future additions) results in an index out of bounds exception being thrown meaning I have to initialise the string array variable with either the exact number of items or less…

If it is not possible to change mappings to a `List<T>`, is there an alternative work around for this?

I am using EntireX 10.5.

---

<div class="post-metadata">

**Author:** ![Finn\_the\_Dane1](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/finn_the_dane1/32/132_2.png) [@Finn\_the\_Dane1](https://techcommunity.softwareag.com/u/Finn_the_Dane1)\
**Post date:** [September 14, 2020, 8:17am UTC](https://techcommunity.softwareag.com/t/entirex-net-client-mappings-from-idl-file-natural-extract/233628/2 "2020-09-14T08:17:19Z")

</div>

The easiest way is to change the Natural subprog parameter with the list to an X-array.  
When you extract this IDL you’ll get nice .NET structures automatically.

For instance:  
1 BankList (1:\*) /\*out  
2 BankID (N10)  
2 BankName (A) dynamic

Finn  
PS if you haven’t used X-arrays before:  
Remember that you have to size the number of elements in the list in the subprog with a  
RESIZE ARRAY BankList (1:I) befor you start putting data into the elements 😉

---

<div class="post-metadata">

**Author:** ![darrylchetty](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/darrylchetty/32/7685_2.png) [@darrylchetty](https://techcommunity.softwareag.com/u/darrylchetty)\
**Post date:** [September 14, 2020, 9:34am UTC](https://techcommunity.softwareag.com/t/entirex-net-client-mappings-from-idl-file-natural-extract/233628/3 "2020-09-14T09:34:42Z")

</div>

Hi Finn

Thank you very much! 😬

I will have a chat with the natural programmer to get X-arrays implemented.

Regards  
Darryl

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 2, 2021, 3:45pm UTC](https://techcommunity.softwareag.com/t/entirex-net-client-mappings-from-idl-file-natural-extract/233628/4 "2021-04-02T15:45:11Z")

</div>


