Share via


AbstractEntityInstance.EntityAsDataRow Method (DataTable)

When overridden in a derived class, exposes the entity instance as a DataRow object in the specified DataTable object.

Namespace:  Microsoft.Office.Server.ApplicationRegistry.Runtime
Assembly:  Microsoft.SharePoint.Portal (in Microsoft.SharePoint.Portal.dll)

Syntax

'Declaration
Public Overridable Function EntityAsDataRow ( _
    tableToAddRowTo As DataTable _
) As DataRow
'Usage
Dim instance As AbstractEntityInstance
Dim tableToAddRowTo As DataTable
Dim returnValue As DataRow

returnValue = instance.EntityAsDataRow(tableToAddRowTo)
public virtual DataRow EntityAsDataRow(
    DataTable tableToAddRowTo
)

Parameters

Return Value

Type: System.Data.DataRow
A DataRow object containing all the fields in the entity instance.

Implements

IEntityInstance.EntityAsDataRow(DataTable)

Remarks

When entity instances are transformed into data rows in a data table, they lose the special semantics attached to them in the Business Data Catalog, such as the ability to call instance methods on them. Therefore, you should transform entity instances into data rows only if absolutely necessary. Avoid using ADO.NET adapters that convert Business Data Catalog return types for maximum performance.

See Also

Reference

AbstractEntityInstance Class

AbstractEntityInstance Members

EntityAsDataRow Overload

Microsoft.Office.Server.ApplicationRegistry.Runtime Namespace