## String::FromAscii(const char *) method


从 ASCII 字符串创建 [String](../)。

```cpp
static String System::String::FromAscii(const char *asciiStr)
```


| Parameter | Type | 描述 |
| --- | --- | --- |
| asciiStr | const char * | 指向使用 ASCII 代码页编码的以空字符结尾的字符串的指针。 |

### ReturnValue

[String](../) object representing passed string.

## 另见

* Class [String](../)
* Class [String](../)
* Namespace [System](../../)
* Library [Aspose.Page for C++](../../../)
## String::FromAscii(const char *, int) method


从 ASCII 字符串创建 [String](../)。

```cpp
static String System::String::FromAscii(const char *asciiStr, int len)
```


| Parameter | Type | 描述 |
| --- | --- | --- |
| asciiStr | const char * | 指向使用 ASCII 代码页编码的字符串的指针。 |
| len | int | 要处理的字符数。 |

### ReturnValue

[String](../) object representing passed string.

## 另见

* Class [String](../)
* Class [String](../)
* Namespace [System](../../)
* Library [Aspose.Page for C++](../../../)
## String::FromAscii(const std::string\&) method


从 ASCII 字符串创建 [String](../)。

```cpp
static String System::String::FromAscii(const std::string &asciiStr)
```


| Parameter | Type | 描述 |
| --- | --- | --- |
| asciiStr | const std::string\& | ASCII 编码的字符串。 |

### ReturnValue

[String](../) object representing passed string.

## 另见

* Class [String](../)
* Class [String](../)
* Namespace [System](../../)
* Library [Aspose.Page for C++](../../../)
