# Nested Classes as generated by .Net Wrapper

**URL:** <https://techcommunity.softwareag.com/t/nested-classes-as-generated-by-net-wrapper/90404>\
**Category:** Forum\
**Tags:** Mainframe-Integration, EntireX\
**Created:** [June 11, 2009, 4:22am UTC](https://techcommunity.softwareag.com/t/nested-classes-as-generated-by-net-wrapper/90404 "2009-06-11T04:22:39Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![JHCloete](https://avatars.discourse-cdn.com/v4/letter/j/0ea827/32.png) [@JHCloete](https://techcommunity.softwareag.com/u/JHCloete)\
**Post date:** [June 11, 2009, 4:22am UTC](https://techcommunity.softwareag.com/t/nested-classes-as-generated-by-net-wrapper/90404/1 "2009-06-11T04:22:39Z")

</div>

I have run into a slight problem where I have defined a group array in my Natural progam on the server side.  
In Visual Studio 2008 using [VB.Net](http://VB.Net) it will not allow me to address the class DetailData. I can however see OutputParm.LineCntA. but not OutputParm.DetailData

Any suggestions will be appreciated.

The code is as follows:  
1 MESSAGE\_DATA Out /\* out  
2 PROGRAM\_ID (A8)  
2 DATE (A10)  
2 TIME (A10)  
2 USERDATA (A64) /\* user defined  
2 RETURN\_CODE (A1)  
2 MSG\_NR (N4)  
2 MESSAGE (A65)  
/\* Message Information  
1 INPUT\_PARM  
2 NAME (A65)  
2 LIC\_NO (A8)  
\*  
1 OUTPUT\_PARM  
2 LINE\_CNT\_A (A3)  
2 DETAIL\_DATA (/1:50)  
3 NAME\_TP (A8)  
3 NAME (A65)  
3 LIC\_NO\_A (A8)  
3 CITY (A25)  
3 STATUS (A10)  
3 LAST\_NAME (A65)

The .Net Wrapper generates the following Class with nested a nested Class.  
#region Groups for LIBRARY ‘LBRPCLIC’, PROGRAM ‘N69000L0’

public class N69000l0  
{  
public class MessageData  
{  
[SendAs(IdlType.A, Length=8f, Id=0, Trim=false)]public StringBuilder programId ;  
[SendAs(IdlType.A, Length=10f, Id=1, Trim=false)]public StringBuilder date ;  
[SendAs(IdlType.A, Length=10f, Id=2, Trim=false)]public StringBuilder time ;  
[SendAs(IdlType.A, Length=64f, Id=3, Trim=false)]public StringBuilder userdata ;  
[SendAs(IdlType.A, Length=1f, Id=4, Trim=false)]public StringBuilder returnCode ;  
[SendAs(IdlType.N, preDecimal=4, postDecimal=0, Id=5)]public decimal msgNr;  
[SendAs(IdlType.A, Length=65f, Id=6, Trim=false)]public StringBuilder message ;  
}  
public class InputParm  
{  
[SendAs(IdlType.A, Length=65f, Id=0, Trim=false)]public StringBuilder name ;  
[SendAs(IdlType.A, Length=8f, Id=1, Trim=false)]public StringBuilder licNo ;  
}  
public class OutputParm  
{  
[SendAs(IdlType.A, Length=3f, Id=0, Trim=false)]public StringBuilder lineCntA ;  
[SendAs(IdlType.Group, Id=1, Dim=50f)]public DetailData detailData = (DetailData)Construction.GroupArray(typeof(DetailData), 50 , 0 , 0 );  
public class DetailData  
{  
[SendAs(IdlType.A, Length=8f, Id=0, Trim=false)]public StringBuilder nameTp ;  
[SendAs(IdlType.A, Length=65f, Id=1, Trim=false)]public StringBuilder name ;  
[SendAs(IdlType.A, Length=8f, Id=2, Trim=false)]public StringBuilder licNoA ;  
[SendAs(IdlType.A, Length=25f, Id=3, Trim=false)]public StringBuilder city ;  
[SendAs(IdlType.A, Length=10f, Id=4, Trim=false)]public StringBuilder status ;  
[SendAs(IdlType.A, Length=65f, Id=5, Trim=false)]public StringBuilder lastName ;  
}  
}  
}

Thanks  
Hennie.

+1 916 600 0789

---

<div class="post-metadata">

**Author:** ![Dietmar\_Gartner](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/dietmar_gartner/32/127_2.png) [@Dietmar\_Gartner](https://techcommunity.softwareag.com/u/Dietmar_Gartner)\
**Post date:** [July 7, 2009, 6:40pm UTC](https://techcommunity.softwareag.com/t/nested-classes-as-generated-by-net-wrapper/90404/2 "2009-07-07T18:40:51Z")

</div>

Hi Hennie,

there are some special considerations with nested classes and [VB.NET](http://VB.NET) which is not case-sensitive and thus can run into name conflicts. To avoid this you can define a ‘Class name prefix for inner classes’ in the properties of the IDL file.

Regards, Dietmar

---

<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, 2:57pm UTC](https://techcommunity.softwareag.com/t/nested-classes-as-generated-by-net-wrapper/90404/3 "2021-04-02T14:57:08Z")

</div>


