服务热线
153 8323 9821
指示指定的字符串是 null 还是 Empty 字符串。其实就是判断字符串是空引用,或值为空。如刚定义一个字符串就是Empty(空)的。
命名空间: System
程序集: mscorlib(在 mscorlib.dll 中)
result = s == null || s == String.Empty;
语法:
public static bool IsNullOrEmpty(
string value
)