IDwTable.Columns Property
.NET Standard 2.x
Gets an IReadOnlyList<IDwColumn>
object which contains the specifications for the columns.
Namespace: DWNet.Data
Assembly: DWNet.Data.dll
Syntax
IReadOnlyList<IDwColumn> Columns { get; }
Property Value
System.Collections.Generic.IReadOnlyList<DWNet.Data.IDwColumn>
An IReadOnlyList<IDwColumn>
object which contains the specifications for the columns.
Examples
The following code example demonstrates how to get the DataWindow.Table.Columns property.
using DWNet.Data;
using System;
namespace Appeon.ApiDoc.IDwTableExamples
{
public class ColumnsExample
{
private readonly SchoolContext _context;
public ColumnsExample(SchoolContext context)
{
_context = context;
}
public void Example()
{
// Creates a DataStore.
var course = new DataStore("d_course", _context);
// Gets columns.
var columns = course.DwMeta.DataWindow.Table.Columns;
// Outputs column names.
Console.WriteLine("Column Count: {0}", columns.Count);
foreach(var column in columns)
{
Console.WriteLine("Column Name: {0}", column.Name);
}
/*This code produces the following output:
Column Count: 4
Column Name: courseid
Column Name: title
Column Name: credits
Column Name: departmentid
*/
}
}
}
Applies to
.NET Standard
2.x