Click or drag to resize

PartServicesGetRelatedParts Method

Retrieves the definitions of all parts related to the specified parent part. The kind of related parts can be filtered using the relatedTypes flagged, enumerated parameter.

Namespace:  FactoryLogix.xTend.PartDefinition
Assembly:  FactoryLogix.xTend.API (in FactoryLogix.xTend.API.dll) Version: 8.242.0.0 (8.242.0.0)
Syntax
public IEnumerable<PartBase> GetRelatedParts(
	Guid sessionId,
	PartBase parentPart,
	PartKind relatedTypes
)

Parameters

sessionId
Type: SystemGuid
The session identifier that was returned by the Connect(String, String, String, String, String) method.
parentPart
Type: FactoryLogix.xTend.DataObjectsPartBase
The part whose relationships are sought. This may be any kind of part. The Id property of the object must be valid.
relatedTypes
Type: FactoryLogix.xTend.DataObjectsPartKind
A flagged, enumerated value indicating the kinds of related parts that are sought. For example, if parentPart is an InternalPart, and you wish to retrieve the AML (Approved Manufacturer Parts), specify a partKind of PartKind.Manufacturer, or 4.

Return Value

Type: IEnumerablePartBase
A list of related parts of types derived from PartBase
Exceptions
ExceptionCondition
InvalidSessionExceptionThrown if the sessionId parameter is invalid.
NotFoundExceptionThe specified parentPart was not found in the system.
NotAuthorizedExceptionThrown when not authorized to perform the function.
See Also