类库说明文档
![]() | JHFileWriterText Method (String, String, Boolean) |
用 UTF-8 格式的编码,向文件中写字符串
Namespace: DCSoft.Utility.IO
Assembly: DCSoft.Utility (in DCSoft.Utility.dll) Version: 0.0.0.0 (1.0.0.0)

C#
public static bool WriterText( string filePath, string text, bool append )
Parameters
- filePath
- Type: SystemString
要读取的完整文件路径 - text
- Type: SystemString
要写入的内容 - append
- Type: SystemBoolean
确定是否将数据追加到文件。如果该文件存在,并且 append 为 false,则该文件被覆盖。如果该文件存在,并且 append 为 true,则数据被追加到该文件中。否则,将创建新文件。
Return Value
Type: Boolean返回一个值,该值指示当前写入是否成功
