# IgnoreCase
{: .no_toc }

Returns or sets whether letter case is ignored when the pattern is matched.

## Get

Returns a **Boolean**.

Syntax: *object*.**IgnoreCase**

*object*
: *required* An object expression that evaluates to a **RegExp**.

The default value is **False**.

## Let

Sets the value.

Syntax: *object*.**IgnoreCase** **=** *value*

*value*
: A **Boolean**. **True** makes matches case-insensitive. **False** makes them case-sensitive.

## Remarks

Unlike [**Global**](/tB/Packages/Contributed/tbRegExp/RegExp/Global.md), [**MultiLine**](/tB/Packages/Contributed/tbRegExp/RegExp/MultiLine.md) and [**DotAll**](/tB/Packages/Contributed/tbRegExp/RegExp/DotAll.md), this option is part of the compiled pattern. Setting it to a different value makes the pattern compile again the next time it is needed, and [**IsValid**](/tB/Packages/Contributed/tbRegExp/RegExp/IsValid.md), [**LastError**](/tB/Packages/Contributed/tbRegExp/RegExp/LastError.md) and [**LastErrorNumber**](/tB/Packages/Contributed/tbRegExp/RegExp/LastErrorNumber.md) then refer to the new compilation. Setting it to its current value does nothing.

The flag `i` of [**Flags**](/tB/Packages/Contributed/tbRegExp/RegExp/Flags.md) reads and sets the same value.

## Example

```tb check_build check_run
Dim re As RegExp
Set re = New RegExp
re.Pattern = "hello"
Debug.Print re.Test("Hello World")  ' False

re.IgnoreCase = True
Debug.Print re.Test("Hello World")  ' True
```

## See Also

- [Flags](/tB/Packages/Contributed/tbRegExp/RegExp/Flags.md) property -- sets this option with the letter `i`
- [Pattern](/tB/Packages/Contributed/tbRegExp/RegExp/Pattern.md) property -- the regular expression
- [IsValid](/tB/Packages/Contributed/tbRegExp/RegExp/IsValid.md) property -- whether the pattern compiles
- [RegExp](/tB/Packages/Contributed/tbRegExp/RegExp/index.md) class -- overview
