否则写全命名空间:System.Web.HttpContext.Current.Server.MapPath();

注意:如果是在一个类库下的一个类中、要先添加引入using System.Web;因为新建一个类库时默认是不引入using System.Web的!

相关文章: