RingSoft.DbLookup.Controls.WPF.Properties Namespace
RingSoft.DbMaintenance Namespace

FieldDefinition..::..SetParentField Method

Sets the parent foreign key definition. For use only by the Entity Framework classes.

Namespace:  RingSoft.DbLookup.ModelDefinition.FieldDefinitions
Assembly:  RingSoft.DbLookup (in RingSoft.DbLookup.dll)

Syntax


public ForeignKeyDefinition SetParentField(
	FieldDefinition parentFieldDefinition,
	string propertyName
)
Public Function SetParentField ( _
	parentFieldDefinition As FieldDefinition, _
	propertyName As String _
) As ForeignKeyDefinition
public:
ForeignKeyDefinition^ SetParentField(
	FieldDefinition^ parentFieldDefinition, 
	String^ propertyName
)

Parameters

parentFieldDefinition
Type: RingSoft.DbLookup.ModelDefinition.FieldDefinitions..::..FieldDefinition
The parent field definition.
propertyName
Type: String
The object's property name

Return Value

This object.

Exceptions


ExceptionCondition
ExceptionTable Definition '{TableDefinition.TableName}' already has a parent join defined. You need to add a field to the ParentJoinForeignKey object instead.