.NET Framework Primitive Value Types

The .NET Framework Base Class Library provides lots of built-in value types that you can use according to your needs. Each value type is a structure exposed by the Base Class Library.

Visual Basic 2015 provides reserved words that are counterparts of the most common value type names. For example, the System.Int32 value type has an alias in the Integer reserved word. The following two lines of code are perfectly equivalent:

Dim anInteger As System.Int32 = 0Dim anInteger As Integer = 0

You can use the .NET names and the Visual Basic reserved words interchangeably when referring to built-in value types.

Naming Conventions

Although you are allowed to invoke value types with both ...

Get Visual Basic 2015 Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.