Collapse AllExpand All      Code: All Code: Multiple Code: Visual Basic Code: C# Code: Visual C++ Code: F# Code: JScript 
Int32 Structure

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

Represents a 32-bit signed integer.

Namespace:   System
Assembly:  mscorlib (in mscorlib.dll)
<SerializableAttribute> _
Public Structure Int32
[SerializableAttribute]
public struct Int32
[SerializableAttribute]
public value class Int32
[<Sealed>]
[<SerializableAttribute>]
type Int32 =  struct end
JScript supports the use of structures, but not the declaration of new ones.

The Int32 type exposes the following members.

  NameDescription
Public method EqualsIndicates whether this instance and a specified object are equal. (Inherited from ValueType.)
Public method GetHashCodeServes as a hash function for a particular type. (Inherited from Object.)
Public method GetTypeGets the Type of the current instance. (Inherited from Object.)
Public method Static member ParseConverts the string representation of a number to its 32-bit signed integer equivalent.
Public method ToString()()()()Converts the numeric value of this instance to its equivalent string representation. (Overrides Object..::..ToString()()()().)
Public method ToString(String)Converts the numeric value of this instance to its equivalent string representation, using the specified format.
Top
  NameDescription
Public field Static member MaxValueRepresents the largest possible value of an Int32. This field is constant.
Public field Static member MinValueRepresents the smallest possible value of Int32. This field is constant.
Top

Int32 is an immutable value type that represents signed integers with values that range from negative 2,147,483,648 (which is represented by the Int32..::..MinValue constant) through positive 2,147,483,647 (which is represented by the Int32..::..MaxValue constant. The .NET Framework also includes an unsigned 32-bit integer value type, UInt32, which represents values that range from 0 to 4,294,967,295.

All members of this type are thread safe. Members that appear to modify instance state actually return a new instance initialized with the new value. As with any other type, reading and writing to a shared variable that contains an instance of this type must be protected by a lock to guarantee thread safety.