I am creating a VB.NET windows app in VS.NET 2003. The app is very simple in that I am just trying to become familiar with using the StringBuilder object. I have a single button on the form and in the click event for the button I am trying to create a new StringBuilder object.
I have included the Imports System.Text statement at the top of the code. When I enter:
Dim sb As StringBuilder = New StringBuilder("text"
I get a squiggly line under the word StringBuilder (the first one) and the tooltip says 'Type expected'. The strange thing is that I have sample code that I downloaded from a book I am working with and it appears to be setup identically and it works, so the problem does not appear to be a strange configuration issue with my machine.
Is the StringBuilder object limited in where it can be created? Anyone have ideas what the problem is? Thanks in advance.
I have included the Imports System.Text statement at the top of the code. When I enter:
Dim sb As StringBuilder = New StringBuilder("text"
I get a squiggly line under the word StringBuilder (the first one) and the tooltip says 'Type expected'. The strange thing is that I have sample code that I downloaded from a book I am working with and it appears to be setup identically and it works, so the problem does not appear to be a strange configuration issue with my machine.
Is the StringBuilder object limited in where it can be created? Anyone have ideas what the problem is? Thanks in advance.