ContextLinkCollection.Add Method
Adds a new ContextLink object to the ContextLinkCollection, indicating the destination node and its direction.
Namespace: Microsoft.Ink
Assembly: Microsoft.Ink.Analysis (in Microsoft.Ink.Analysis.dll)
Syntax
'Declaration
Public Function Add ( _
destinationNode As ContextNode, _
linkDirection As ContextLinkDirection _
) As ContextLink
'Usage
Dim instance As ContextLinkCollection
Dim destinationNode As ContextNode
Dim linkDirection As ContextLinkDirection
Dim returnValue As ContextLink
returnValue = instance.Add(destinationNode, _
linkDirection)
public ContextLink Add(
ContextNode destinationNode,
ContextLinkDirection linkDirection
)
public:
ContextLink^ Add(
ContextNode^ destinationNode,
ContextLinkDirection linkDirection
)
public function Add(
destinationNode : ContextNode,
linkDirection : ContextLinkDirection
) : ContextLink
Parameters
destinationNode
Type: Microsoft.Ink.ContextNodeThe ContextNode to be linked to.
linkDirection
Type: Microsoft.Ink.ContextLinkDirectionThe link direction.
Return Value
Type: Microsoft.Ink.ContextLink
The new ContextLink object.
Remarks
The ContextNode this collection is associated with becomes the SourceNode in the new ContextLink object.
The ContextLink object is also added to the DestinationNode object's Links property.
Examples
The following example adds a link between an InkDrawingNode object, drawing, and an InkWordNode object, word.
drawing.Links.Add(word, Microsoft.Ink.ContextLinkDirection.LinksWith)
drawing.Links.Add(word, Microsoft.Ink.ContextLinkDirection.LinksWith);
Platforms
Windows 7, Windows Vista, Windows Server 2008 R2, Windows Server 2008
The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Version Information
.NET Framework
Supported in: 3.0