> ## 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.

# NSImportLine

> Used to import data into the system. Representing one entity that will be imported.

Used to import data into the system. Representing one entity that will be imported.

## Constructors

### NSImportLine()

```crmscript theme={null}
NSImportLine
```

Initializes a new instance of the NSImportLine class.

## Methods

## GetExternalKey()

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

**Returns:** [CRMScript.Global.String](CRMScript.Global.String) - Optional external primary key for the row.

**Example:**

```crmscript theme={null}
NSImportLine thing;
String externalKey = thing.GetExternalKey();
```

## GetOperation()

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

**Returns:** [CRMScript.Global.Integer](CRMScript.Global.Integer) - Which operation will be used? This is a read-only property. See \<xref href="CRMScript.NetServer.ImportAction" data-throw-if-not-resolved="false">\</xref>.

**Example:**

```crmscript theme={null}
NSImportLine thing;
Integer operation = thing.GetOperation();
```

## GetSelected()

```crmscript theme={null}
Bool GetSelected()
```

**Returns:** [CRMScript.Global.Bool](CRMScript.Global.Bool) - True if the entity shall be imported, false if the entity shall be ignored.

**Example:**

```crmscript theme={null}
NSImportLine thing;
Bool selected = thing.GetSelected();
```

## GetType()

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

**Returns:** [CRMScript.Global.Integer](CRMScript.Global.Integer) - Which entity type will be created? This is a read-only property. See \<xref href="CRMScript.NetServer.ImportEntityType" data-throw-if-not-resolved="false">\</xref>.

**Example:**

```crmscript theme={null}
NSImportLine thing;
Integer type = thing.GetType();
```

## GetValues()

```crmscript theme={null}
String[] GetValues()
```

**Returns:** [CRMScript.Global.String](CRMScript.Global.String)\[] - An array of the values that will be imported on the entity.

**Example:**

```crmscript theme={null}
NSImportLine thing;
String[] values = thing.GetValues();
```

## SetExternalKey(String)

```crmscript theme={null}
Void SetExternalKey(String externalKey)
```

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

**Example:**

```crmscript theme={null}
NSImportLine thing;
String externalKey;
thing.SetExternalKey(externalKey);
```

## SetOperation(Integer)

```crmscript theme={null}
Void SetOperation(Integer operation)
```

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

**Example:**

```crmscript theme={null}
NSImportLine thing;
Integer operation;
thing.SetOperation(operation);
```

## SetSelected(Bool)

```crmscript theme={null}
Void SetSelected(Bool selected)
```

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

**Example:**

```crmscript theme={null}
NSImportLine thing;
Bool selected;
thing.SetSelected(selected);
```

## SetType(Integer)

```crmscript theme={null}
Void SetType(Integer type)
```

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

**Example:**

```crmscript theme={null}
NSImportLine thing;
Integer type;
thing.SetType(type);
```

## SetValues(String\[])

```crmscript theme={null}
Void SetValues(String[] values)
```

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

**Example:**

```crmscript theme={null}
NSImportLine thing;
String[] values;
thing.SetValues(values);
```


## Related topics

- [NSImportAgent](/en/automation/crmscript/reference/CRMScript.NetServer.NSImportAgent.md)
- [NSImportErpData](/en/automation/crmscript/reference/CRMScript.NetServer.NSImportErpData.md)
- [Create Default Import Line](/en/api/reference/restful/agent/import_agent/create-default-import-line.md)
- [SuperOffice.WebApi.Data.Import CreateDefaultImportLineRequest](/en/api/reference/webapi/SuperOffice.WebApi.Data.Import_CreateDefaultImportLineRequest.md)
- [SuperOffice.WebApi.Data.ImportLine](/en/api/reference/webapi/SuperOffice.WebApi.Data.ImportLine.md)
- [SuperOffice.WebApi.Data.ImportErpData](/en/api/reference/webapi/SuperOffice.WebApi.Data.ImportErpData.md)
