
## replace_to_images_regex(input_file_name, save_options, pattern, replacement, options) {#str_imagesaveoptions_str_str_findreplaceoptions}

Replaces all occurrences of a specified regular expression pattern with a replacement string in the input file.
Renders output to images.


```python
def replace_to_images_regex(self, input_file_name: str, save_options: aspose.words.saving.ImageSaveOptions, pattern: str, replacement: str, options: aspose.words.replacing.FindReplaceOptions):
    ...
```

| Parameter | Type | Description |
| --- | --- | --- |
| input_file_name | str | The input file name. |
| save_options | [ImageSaveOptions](../../../aspose.words.saving/imagesaveoptions/) | The save options. |
| pattern | str | A regular expression pattern used to find matches. |
| replacement | str | A string to replace all occurrences of pattern. |
| options | [FindReplaceOptions](../../../aspose.words.replacing/findreplaceoptions/) | [FindReplaceOptions](../../../aspose.words.replacing/findreplaceoptions/) object to specify additional options. |

## replace_to_images_regex(input_file_name, save_options, pattern, replacement) {#str_imagesaveoptions_str_str}

Replaces all occurrences of a specified regular expression pattern with a replacement string in the input file.
Renders output to images.


```python
def replace_to_images_regex(self, input_file_name: str, save_options: aspose.words.saving.ImageSaveOptions, pattern: str, replacement: str):
    ...
```

| Parameter | Type | Description |
| --- | --- | --- |
| input_file_name | str | The input file name. |
| save_options | [ImageSaveOptions](../../../aspose.words.saving/imagesaveoptions/) | The save options. |
| pattern | str | A regular expression pattern used to find matches. |
| replacement | str | A string to replace all occurrences of pattern. |

## replace_to_images_regex(input_stream, save_options, pattern, replacement, options) {#bytesio_imagesaveoptions_str_str_findreplaceoptions}

Replaces all occurrences of a specified regular expression pattern with a replacement string in the input file.
Renders output to images.


```python
def replace_to_images_regex(self, input_stream: io.BytesIO, save_options: aspose.words.saving.ImageSaveOptions, pattern: str, replacement: str, options: aspose.words.replacing.FindReplaceOptions):
    ...
```

| Parameter | Type | Description |
| --- | --- | --- |
| input_stream | io.BytesIO | The input file stream. |
| save_options | [ImageSaveOptions](../../../aspose.words.saving/imagesaveoptions/) | The save options. |
| pattern | str | A regular expression pattern used to find matches. |
| replacement | str | A string to replace all occurrences of pattern. |
| options | [FindReplaceOptions](../../../aspose.words.replacing/findreplaceoptions/) | [FindReplaceOptions](../../../aspose.words.replacing/findreplaceoptions/) object to specify additional options. |

## replace_to_images_regex(input_stream, save_options, pattern, replacement) {#bytesio_imagesaveoptions_str_str}

Replaces all occurrences of a specified regular expression pattern with a replacement string in the input file.
Renders output to images.


```python
def replace_to_images_regex(self, input_stream: io.BytesIO, save_options: aspose.words.saving.ImageSaveOptions, pattern: str, replacement: str):
    ...
```

| Parameter | Type | Description |
| --- | --- | --- |
| input_stream | io.BytesIO | The input file stream. |
| save_options | [ImageSaveOptions](../../../aspose.words.saving/imagesaveoptions/) | The save options. |
| pattern | str | A regular expression pattern used to find matches. |
| replacement | str | A string to replace all occurrences of pattern. |

## See Also

* module [aspose.words.lowcode](../../)
* class [Replacer](../)

