# TXBarcodeControl.BarcodeType Property

> Gets or sets the type of barcode that should be displayed. This is a dependency property.

- **Product:** TX Text Control .NET for WPF
- **Section:** Reference
- **Kind:** Property
- **Introduced:** 29.0
- **Namespace:** `TXTextControl.WPF.Barcode`
- **Package:** `TXTextControl.TextControl.WPF.SDK` (assembly `TXBarcode.WPF.dll`, from the private NuGet feed or Text Control Offline Packages)
- **.NET Framework:** reference `TXBarcode.WPF.dll` from the setup
- **Path:** TX Text Control .NET for WPF > Reference > TXTextControl.WPF.Barcode > TXBarcodeControl.BarcodeType Property
- **434 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf-barcode/txbarcodecontrol/barcodetype-property/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf-barcode/txbarcodecontrol/barcodetype-property/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf-barcode/txbarcodecontrol/barcodetype-property/llms-full.txt

---

### Description

Gets or sets the [type of barcode](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-barcode/barcodetype/enumeration/llms-full.txt) that should be displayed. This is a dependency property.

### Syntax

```csharp
public BarcodeType BarcodeType { get; set; }
```

```vbnet
Public Property BarcodeType As BarcodeType
```

### Examples

The following example uses `TXBarcodeControl.BarcodeType` to configure barcode type as part of the txbarcode control workflow. The configured value is checked before the workflow continues.

```csharp
tXBarcodeControl.BarcodeType = TXTextControl.Barcode.BarcodeType.QRCode;
Console.WriteLine($"Barcode Type used by TXBarcode Control: {tXBarcodeControl.BarcodeType}");
```

```vbnet
tXBarcodeControl.BarcodeType = TXTextControl.Barcode.BarcodeType.QRCode
Console.WriteLine($"Barcode Type used by TXBarcode Control: {tXBarcodeControl.BarcodeType}")
```

### Remarks

On changing this property all control settings are retained, if they are valid for the conditions of the new barcode type. Otherwise the [Text](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf-barcode/txbarcodecontrol/text-property/llms-full.txt) and [UpperTextLength](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf-barcode/txbarcodecontrol/uppertextlength-property/llms-full.txt) properties are reset to the default values of the new barcode type.

---

## Nearby

- **Previous:** [TXBarcodeControl.BackColor Property](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf-barcode/txbarcodecontrol/backcolor-property/llms-full.txt)
- **Next:** [TXBarcodeControl.BarcodeTypeSettings Property](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf-barcode/txbarcodecontrol/barcodetypesettings-property/llms-full.txt)
