当前位置:首页 > windos > 正文

C# DataTable扩展方法

在日常搬砖中,总结了一些简单的扩展方法。

        public static bool IsNullOrEmpty(this DataTable dt)
        {
            return dt == null || dt.Rows.Count <= 0;
        }
        public static bool IsNotEmpty(this DataTable dt)
        {
            return dt.IsNullOrEmpty() == false;
        }

 

上一篇
API+RESTful

下一篇
C#基本语法