JHFile.ReadText Method (String, Encoding)

DCSoft.DBUtilityGeneric

JHFileReadText Method (String, Encoding)
用指定的字符编码,从文件中读取字符串形式的流,文件不存在或异常返回 string.Empty

Namespace: DCSoft.Utility.IO
Assembly: DCSoft.Utility (in DCSoft.Utility.dll) Version: 0.0.0.0 (1.0.0.0)
Syntax
C#
public static string ReadText(
	string filePath,
	Encoding encoding
)

Parameters

filePath
Type: SystemString
要读取的完整文件路径
encoding
Type: System.TextEncoding
要使用的字符编码

Return Value

Type: String
返回字符串形式的流
See Also