## Path::ChangeExtension method


更改指定文件路径中的扩展名。

```cpp
static String System::IO::Path::ChangeExtension(const String &path, const String &extension)
```


| 参数 | 类型 | 描述 |
| --- | --- | --- |
| 路径 | const String\& | 文件路径 |
| 扩展名 | const String\& | 要替换 **path** 中扩展名的扩展名 |

### ReturnValue

**path** with extension replaced with **extension**

## 另见

* Class [String](../../../system/string/)
* Class [Path](../)
* Namespace [System::IO](../../)
* Library [Aspose.Font for C++](../../../)
