This version is out of date, covering development from v9.0.0 to v9.3.0. It is maintained here only for inbound reference links from elsewhere. It is no longer actively updated.

Jump to the current version of aTbRef

Tinderbox v9 Icon

createLink(sourceItem,destinationItem[,linkType])


Operator Type: 

Operator Scope of Action: 

Operator Purpose: 

Operator First Added: 

Operator Altered: 

 Function   [other Function type actions]

 Item   [operators of similar scope]

 Linking   [other Linking operators]

 9.1.0

 


createLink(sourceItem,destinationItem[,linkType])

From v9.1.0, createLink() can be used for link creation. This is useful when neither the source nor the destination of the link are this note. The arguments sourceItem and destinationItem must be defined so as to identify a single (existing) item.

Example:

	$MyList2.each(anItem2){
		$MyList.each(anItem1){
			createLink(anItem1,anItem2);
		};
	};

createLink() may also cope better than linkTo() and linkFrom() with the edge case when a note's $Name (or those of other notes in the note's path) contain forward slashes. Such paths are challenge as in string form the differing meaning of the use of slashes (container delimiter vs. note title) is ambiguous to the parser.



A Tinderbox Reference File : Actions & Rules : Operators : Full Operator List : createLink(sourceItem,destinationItem[,linkType])