BitArray.Or Method (BitArray)


Performs the bitwise OR operation between the elements of the current BitArray object and the corresponding elements in the specified array. The current BitArray object will be modified to store the result of the bitwise OR operation.

Namespace:   System.Collections
Assembly:  mscorlib (in mscorlib.dll)

member Or : 
        value:BitArray -> BitArray


Type: System.Collections.BitArray

The array with which to perform the bitwise OR operation.

Return Value

Type: System.Collections.BitArray

An array containing the result of the bitwise OR operation, which is a reference to the current BitArray object.

Exception Condition

value is null.


value and the current BitArray do not have the same number of elements.

The bitwise OR operation returns true if one or both operands are true, and returns false if both operands are false.

This method is an O(n) operation, where n is Count.

The following code example shows how to perform the OR operation between two BitArray objects.

No code example is currently available or this language may not be supported.

Universal Windows Platform
Available since 8
.NET Framework
Available since 1.1
Portable Class Library
Supported in: portable .NET platforms
Available since 2.0
Windows Phone Silverlight
Available since 7.0
Windows Phone
Available since 8.1
Return to top