Try OpenEdge Now
skip to main content
GUI for .NET Programming
Using .NET data types in ABL : Implicit data type mappings : Implicit array mappings
 

Implicit array mappings

Table 10 shows the implicit mappings between ABL primitive types and .NET mapped data types. Note that all of the listed ABL primitive types, except BLOB and CLOB, can also be defined as elements of an ABL array (using the EXTENT option). ABL similarly supports implicit mappings between ABL arrays of these primitive types and .NET one-dimensional arrays of the corresponding .NET mapped data types (.NET arrays of mapped types). Note that unlike ABL arrays, all .NET arrays are objects—classes whose object type names consist of the .NET type name of the array element following by a pair of square brackets ([]) containing a comma for each additional dimension of the array beyond one (for example, [,] specifies two dimensions). In ABL, you must surround the entire .NET array type name with double-quotes because the brackets and commas represent special characters in ABL names.
So, for example, you can assign an ABL INTEGER array to a writable .NET property defined as a "System.Int32[]" (or C# int[]), and you can assign a readable .NET property defined as a "System.Int32[]" (or C# int[]) to an ABL INTEGER array. In each case, ABL converts the source array type to the target array type. This same implicit array mapping also works for passing .NET method parameters.
For more information on working with and mapping .NET arrays in ABL, see Accessingand using .NET arrays.