Skip to content

Latest commit

 

History

History
33 lines (30 loc) · 1.59 KB

File metadata and controls

33 lines (30 loc) · 1.59 KB
title How to: Create Strings Using a StringBuilder in Visual Basic
ms.custom
ms.date 07/20/2015
ms.prod .net
ms.reviewer
ms.suite
ms.technology
devlang-visual-basic
ms.topic article
helpviewer_keywords
StringBuilder class
strings [Visual Basic], using StringBuilder
ms.assetid 9c042880-aa16-432e-9ccb-cd00abda9ae3
caps.latest.revision 9
author dotnet-bot
ms.author dotnetcontent

How to: Create Strings Using a StringBuilder in Visual Basic

This example constructs a long string from many smaller strings using the xref:System.Text.StringBuilder class. The xref:System.Text.StringBuilder class is more efficient than the &= operator for concatenating many strings.

Example

The following example creates an instance of the xref:System.Text.StringBuilder class, appends 1,000 strings to that instance, and then returns its string representation.

[!code-vbVbVbalrStrings#70]

See Also

Using the StringBuilder Class
&= Operator
Strings
Creating New Strings
Manipulating Strings
Strings Sample