combit List & Label 24 - .NET Online Web Help
ChildColumnName Property
Example 


combit.ListLabel24.DataProviders Namespace > ITableRelation Interface : ChildColumnName Property

This property is accessed to query the child key column name. Combined keys can be passed with the separator "\t". Your data provider should therefore deliver for example "CustomerID\tOrderID" and the corresponding child fields. In the ApplyFilter() Method of the ITable Interface the values are arriving exactly like that, a filter string could look like following:

"CustomerID\tOrderID=22\t14"

The GetChildTable() Method of the ITableRow Interface directly gets a ITableRelation Interface, so that you also have access to the combined fields there.

Syntax
'Declaration
 
ReadOnly Property ChildColumnName As String
string ChildColumnName {get;}
property String^ ChildColumnName {
   String^ get();
}
Example
class DataRelationWrapper : ITableRelation
{
    private DataRelation _dataRelation;
    public DataRelationWrapper(DataRelation dataRelation)
    {
        _dataRelation = dataRelation;
    }
    #region IDataRelation Members

    public string RelationName
    {
        get { return _dataRelation.RelationName; }
    }

    public string ParentColumnName
    {
        get { return _dataRelation.ParentColumns[0].ColumnName; }
    }

    public string ChildColumnName
    {
        get { return _dataRelation.ChildColumns[0].ColumnName; }
    }

    public string ParentTableName
    {
        get { return _dataRelation.ParentColumns[0].Table.TableName; }
    }

    public string ChildTableName
    {
        get { return _dataRelation.ChildColumns[0].Table.TableName; }
    }

    #endregion
}
Class DataRelationWrapper
    Implements ITableRelation
    Private _dataRelation As DataRelation
    Public Sub New(dataRelation As DataRelation)
        _dataRelation = dataRelation
    End Sub
    #region IDataRelation Members

    Public Readonly Property RelationName() As String
        Get
            Return _dataRelation.RelationName
        End Get
    End Property

    Public Readonly Property ParentColumnName() As String
        Get
            Return _dataRelation.ParentColumns(0).ColumnName
        End Get
    End Property

    Public Readonly Property ChildColumnName() As String
        Get
            Return _dataRelation.ChildColumns(0).ColumnName
        End Get
    End Property

    Public Readonly Property ParentTableName() As String
        Get
            Return _dataRelation.ParentColumns(0).Table.TableName
        End Get
    End Property

    Public Readonly Property ChildTableName() As String
        Get
            Return _dataRelation.ChildColumns(0).Table.TableName
        End Get
    End Property
#End Region
End Class
Requirements

Platforms: Windows Vista - Windows 10 Version 1809, Windows Server 2008 - 2016

See Also

Reference

ITableRelation Interface
ITableRelation Members