Sets the 'related_id' property to an item reference.

Namespace:  Aras.IOM
Assembly:  IOM (in IOM.dll) Version: 11.0.0.6296

Syntax

C#
public void setRelatedItem(
	Item ritem
)
Visual Basic (Declaration)
Public Sub setRelatedItem ( _
	ritem As Item _
)
J#
public void setRelatedItem(
	Item ritem
)
JScript
public function setRelatedItem(
	ritem : Item
)

Parameters

ritem
Type: Aras.IOM..::.Item
Related item

Remarks

The method is trying to find 'related_id' property on the item. If not found, creates it. If 'related_id' contains child <Item> node, replace it with the passed item, else append passed item to the 'related_id' node. After the method was called, the passed related item shares its dom with this item (i.e. dom property of both instances reference the same instance of ArasXmlDocument).

Exceptions

ExceptionCondition
System..::.Exception
  • The instance doesn't represent a single item.
  • The instance has a wrong internal structure (e.g. item.node doesn't belong to item.dom; etc.).
System..::.ArgumentException
  • The item passed to the method doesn't represent a single item.
  • this.node is read-only.

See Also