> ## Documentation Index
> Fetch the complete documentation index at: https://docs.superoffice.com/llms.txt
> Use this file to discover all available pages before exploring further.

# NSLink

> Links two entities (contacts/projects/sales/URLs) together.

Links two entities (contacts/projects/sales/URLs) together.

## Constructors

### NSLink()

```crmscript theme={null}
NSLink
```

Initializes a new instance of the NSLink class.

## Methods

## GetDescription()

```crmscript theme={null}
String GetDescription()
```

**Returns:** [CRMScript.Global.String](CRMScript.Global.String) - Link description.

**Example:**

```crmscript theme={null}
NSLink thing;
String description = thing.GetDescription();
```

## GetEntityName()

```crmscript theme={null}
String GetEntityName()
```

**Returns:** [CRMScript.Global.String](CRMScript.Global.String) - Name of the entity the link points to (The destination/target entity).

**Example:**

```crmscript theme={null}
NSLink thing;
String entityName = thing.GetEntityName();
```

## GetExtraInfo()

```crmscript theme={null}
String GetExtraInfo()
```

**Returns:** [CRMScript.Global.String](CRMScript.Global.String) - Extrainfo for link. Use for information that does not have a primary key.

**Example:**

```crmscript theme={null}
NSLink thing;
String extraInfo = thing.GetExtraInfo();
```

## GetId()

```crmscript theme={null}
Integer GetId()
```

**Returns:** [CRMScript.Global.Integer](CRMScript.Global.Integer) - ID of the entity the link points to (The destination/target entity primary key).

**Example:**

```crmscript theme={null}
NSLink thing;
Integer id = thing.GetId();
```

## GetLinkId()

```crmscript theme={null}
Integer GetLinkId()
```

**Returns:** [CRMScript.Global.Integer](CRMScript.Global.Integer) - Primary key.

**Example:**

```crmscript theme={null}
NSLink thing;
Integer linkId = thing.GetLinkId();
```

## SetDescription(String)

```crmscript theme={null}
Void SetDescription(String description)
```

**Returns:** [CRMScript.Global.Void](CRMScript.Global.Void)

**Example:**

```crmscript theme={null}
NSLink thing;
String description;
thing.SetDescription(description);
```

## SetEntityName(String)

```crmscript theme={null}
Void SetEntityName(String entityName)
```

**Returns:** [CRMScript.Global.Void](CRMScript.Global.Void)

**Example:**

```crmscript theme={null}
NSLink thing;
String entityName;
thing.SetEntityName(entityName);
```

## SetExtraInfo(String)

```crmscript theme={null}
Void SetExtraInfo(String extraInfo)
```

**Returns:** [CRMScript.Global.Void](CRMScript.Global.Void)

**Example:**

```crmscript theme={null}
NSLink thing;
String extraInfo;
thing.SetExtraInfo(extraInfo);
```

## SetId(Integer)

```crmscript theme={null}
Void SetId(Integer id)
```

**Returns:** [CRMScript.Global.Void](CRMScript.Global.Void)

**Example:**

```crmscript theme={null}
NSLink thing;
Integer id;
thing.SetId(id);
```

## SetLinkId(Integer)

```crmscript theme={null}
Void SetLinkId(Integer linkId)
```

**Returns:** [CRMScript.Global.Void](CRMScript.Global.Void)

**Example:**

```crmscript theme={null}
NSLink thing;
Integer linkId;
thing.SetLinkId(linkId);
```


## Related topics

- [NSListAgent](/en/automation/crmscript/reference/CRMScript.NetServer.NSListAgent.md)
- [NSProjectEntity](/en/automation/crmscript/reference/CRMScript.NetServer.NSProjectEntity.md)
- [NSSaleEntity](/en/automation/crmscript/reference/CRMScript.NetServer.NSSaleEntity.md)
- [NSDocumentEntity](/en/automation/crmscript/reference/CRMScript.NetServer.NSDocumentEntity.md)
- [NSAppointmentEntity](/en/automation/crmscript/reference/CRMScript.NetServer.NSAppointmentEntity.md)
- [Links](/en/learn/basics/links.md)
