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

# NSProjectTypeEntity

> Carrier object for ProjectTypeEntity.

Carrier object for ProjectTypeEntity.

## Constructors

### NSProjectTypeEntity()

```crmscript theme={null}
NSProjectTypeEntity
```

Initializes a new instance of the NSProjectTypeEntity class.

## Methods

## GetDeleted()

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

**Returns:** [CRMScript.Global.Bool](CRMScript.Global.Bool) - 0 -> record is active 1 -> record is 'deleted' and should not be shown in lists.

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Bool deleted = thing.GetDeleted();
```

## GetDurationUnit()

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

**Returns:** [CRMScript.Global.Integer](CRMScript.Global.Integer) - Units for the duration. See \<xref href="CRMScript.NetServer.DurationUnit" data-throw-if-not-resolved="false">\</xref>.

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Integer durationUnit = thing.GetDurationUnit();
```

## GetHasGuide()

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

**Returns:** [CRMScript.Global.Bool](CRMScript.Global.Bool) - Does this project type have a guide attached.

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Bool hasGuide = thing.GetHasGuide();
```

## GetIsAutoAdvance()

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

**Returns:** [CRMScript.Global.Bool](CRMScript.Global.Bool) - Does the project status advance automatically, when the last guided activity in a status is completed?

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Bool isAutoAdvance = thing.GetIsAutoAdvance();
```

## GetName()

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

**Returns:** [CRMScript.Global.String](CRMScript.Global.String) - The list item.

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
String name = thing.GetName();
```

## GetProjectDuration()

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

**Returns:** [CRMScript.Global.Integer](CRMScript.Global.Integer) - Expected duration of project, in given units.

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Integer projectDuration = thing.GetProjectDuration();
```

## GetProjTypeId()

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

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

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Integer projTypeId = thing.GetProjTypeId();
```

## GetRank()

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

**Returns:** [CRMScript.Global.Integer](CRMScript.Global.Integer) - Rank order.

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Integer rank = thing.GetRank();
```

## GetStages()

```crmscript theme={null}
NSSelectableMDOListItem[] GetStages()
```

**Returns:** [CRMScript.NetServer.NSSelectableMDOListItem](CRMScript.NetServer.NSSelectableMDOListItem)\[] - Stages (project statuses), those associated with this ProjType are selected.

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
NSSelectableMDOListItem[] stages = thing.GetStages();
```

## GetTooltip()

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

**Returns:** [CRMScript.Global.String](CRMScript.Global.String) - Tooltip or other description.

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
String tooltip = thing.GetTooltip();
```

## SetDeleted(Bool)

```crmscript theme={null}
Void SetDeleted(Bool deleted)
```

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

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Bool deleted;
thing.SetDeleted(deleted);
```

## SetDurationUnit(Integer)

```crmscript theme={null}
Void SetDurationUnit(Integer durationUnit)
```

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

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Integer durationUnit;
thing.SetDurationUnit(durationUnit);
```

## SetHasGuide(Bool)

```crmscript theme={null}
Void SetHasGuide(Bool hasGuide)
```

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

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Bool hasGuide;
thing.SetHasGuide(hasGuide);
```

## SetIsAutoAdvance(Bool)

```crmscript theme={null}
Void SetIsAutoAdvance(Bool isAutoAdvance)
```

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

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Bool isAutoAdvance;
thing.SetIsAutoAdvance(isAutoAdvance);
```

## SetName(String)

```crmscript theme={null}
Void SetName(String name)
```

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

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
String name;
thing.SetName(name);
```

## SetProjectDuration(Integer)

```crmscript theme={null}
Void SetProjectDuration(Integer projectDuration)
```

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

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Integer projectDuration;
thing.SetProjectDuration(projectDuration);
```

## SetProjTypeId(Integer)

```crmscript theme={null}
Void SetProjTypeId(Integer projTypeId)
```

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

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Integer projTypeId;
thing.SetProjTypeId(projTypeId);
```

## SetRank(Integer)

```crmscript theme={null}
Void SetRank(Integer rank)
```

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

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
Integer rank;
thing.SetRank(rank);
```

## SetStages(NSSelectableMDOListItem\[])

```crmscript theme={null}
Void SetStages(NSSelectableMDOListItem[] stages)
```

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

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
NSSelectableMDOListItem[] stages;
thing.SetStages(stages);
```

## SetTooltip(String)

```crmscript theme={null}
Void SetTooltip(String tooltip)
```

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

**Example:**

```crmscript theme={null}
NSProjectTypeEntity thing;
String tooltip;
thing.SetTooltip(tooltip);
```


## Related topics

- [NSListAgent](/en/automation/crmscript/reference/CRMScript.NetServer.NSListAgent.md)
- [Samples](/en/automation/crmscript/howto/project/samples.md)
- [Save Project Type Entity](/en/api/reference/restful/agent/list_agent/save-project-type-entity.md)
- [Get Project Type Entity](/en/api/reference/restful/agent/list_agent/get-project-type-entity.md)
- [Create Default Project Type Entity](/en/api/reference/restful/agent/list_agent/create-default-project-type-entity.md)
- [Projects](/en/api/reference/restful/rest/contact/projects.md)
