Publish
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

# Single.PositiveInfinity Field

.NET Framework 1.1

Represents positive infinity. This field is constant.

```[Visual Basic]
Public Const PositiveInfinity As Single
[C#]
public const float PositiveInfinity;
[C++]
public: const float PositiveInfinity;
[JScript]
public var PositiveInfinity : float;```

#### Remarks

The value of this constant is the result of dividing a positive number by zero.

This constant is returned when the result of an operation is greater than MaxValue.

Use IsPositiveInfinity to determine whether a value evaluates to positive infinity. It is not possible to determine whether a value evaluates to positive infinity by comparing it to another value equal to PositiveInfinity.

#### Example

[Visual Basic, C#, C++] The following sample demonstrates the PositiveInfinity constant.

```[Visual Basic]
' This will equal Infinity.
Console.WriteLine("PositiveInfinity plus 10.0 equals " + (Single.PositiveInfinity + 10).ToString() + ".")

[C#]
// This will equal Infinity.
Console.WriteLine("PositiveInfinity plus 10.0 equals {0}.", (Single.PositiveInfinity + 10.0).ToString());

[C++]
// This will equal Infinity.
Console::WriteLine(S"PositiveInfinity plus 10.0 equals {0}.", __box((Single::PositiveInfinity + 10.0)));
```

[JScript] No example is available for JScript. To view a Visual Basic, C#, or C++ example, click the Language Filter button in the upper-left corner of the page.

#### Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, .NET Compact Framework, Common Language Infrastructure (CLI) Standard