# FormattingStyle.Name Property

> Gets or sets the name of the style.

- **Product:** TX Text Control .NET Server
- **Section:** Reference
- **Kind:** Property
- **Introduced:** 10.1
- **Namespace:** `TXTextControl`
- **Package:** `TXTextControl.TextControl.Core.SDK` (assembly `TXTextControl.Core.dll`, from the private NuGet feed or Text Control Offline Packages)
- **Package:** `TXTextControl.TextControl.ASP.SDK` (assembly `TXTextControl.dll`, from the private NuGet feed or Text Control Offline Packages)
- **.NET Framework:** reference `TXTextControl.dll` from the setup
- **Path:** TX Text Control .NET Server > Reference > TXTextControl > FormattingStyle.Name Property
- **502 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol/formattingstyle/name-property/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol/formattingstyle/name-property/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol/formattingstyle/name-property/llms-full.txt

---

### Description

Gets or sets the name of the style.

### Syntax

```csharp
public string Name { get; set; }
```

```vbnet
Public Property Name As String
```

### Examples

The following example creates a reusable emphasis style and adds it to the document by using `FormattingStyle.Name`.

```csharp
FormattingStyle formattingStyle = new InlineStyle("Emphasis");

formattingStyle.Name = "FormattingStyle1";
if (!string.IsNullOrWhiteSpace(formattingStyle.Name))
{
    Console.WriteLine($"Name: {formattingStyle.Name}");
}

textControl.InlineStyles.Add((InlineStyle)formattingStyle);
```

```vbnet
Dim formattingStyle As FormattingStyle = New InlineStyle("Emphasis")

formattingStyle.Name = "FormattingStyle1"
If Not String.IsNullOrWhiteSpace(formattingStyle.Name) Then
    Console.WriteLine($"Name: {formattingStyle.Name}")
End If

textControl.InlineStyles.Add(DirectCast(formattingStyle, InlineStyle))
```

---

## Nearby

- **Previous:** [FormattingStyle.Italic Property](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol/formattingstyle/italic-property/llms-full.txt)
- **Next:** [FormattingStyle.Strikeout Property](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol/formattingstyle/strikeout-property/llms-full.txt)
