---
title: "replacementCheckingResult(range:replacementString:)"
framework: foundation
role: symbol
role_heading: Type Method
path: "foundation/nstextcheckingresult/replacementcheckingresult(range:replacementstring:)"
---

# replacementCheckingResult(range:replacementString:)

Creates and returns a text checking result with the specified replacement string.

## Declaration

```swift
class func replacementCheckingResult(range: NSRange, replacementString: String) -> NSTextCheckingResult
```

## Parameters

- `range`: The range of the detected result.
- `replacementString`: The replacement string.

## Return Value

Return Value Returns an NSTextCheckingResult with the specified range and a resultType of replacement.

## See Also

### Text Checking Results for Text Replacement

- [replacementString](foundation/nstextcheckingresult/replacementstring.md)
