通过vb.net 和NPOI实现对excel的读操作,很久很久前用过vb,这次朋友的代码是vb.net写的需要一个excel的操作, 就顾着着实现功能了,大家凑合着看吧 Option Explicit On Imports NPOI.SS.UserModel Imports System.IO Public Class ExcelHelper Public Shared Function ImportExcel(ByVal strSource As String) As DataTable Di…
以下是代码: using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Xml; namespace WebApplication2 { /// <summary> /// XMLHelper XML文档操作管理器 /// </summary> public class XMLHelper { …
平时使用Linq,习惯了Lambda表达式,用着非常顺手,奈何在Jquery里面不能这样用,只能循环一个个判断.趁空闲时间找了找,自己写了这样的扩展方法.目前写出了三种方案,没有比较性能,觉得都可以用,先贴出来. 方案1(使用$.each): Array.prototype.where = function (callback) { if (typeof this == "object" && this.constructor == Array) { var newAr…
摘要:几个操作SharePoint用户组的方法,已经测试通过,但是没有提升权限,如果没有权限的人操作,需要提升权限(提权代码附后).大家需要的话,可以参考下,写在这里也给自己留个备份~~ //创建用户组 public static bool CreatSPGroup(string strGroupName, string strGroupDescription) { try { using (SPSite site = new SPSite(SiteUrl)) { using (SPWeb we…