随笔分类 -  asp.net

asp.net方面的知识
摘要:using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Collections;using System.Web;namespace Utility{ public class DataCache { /// <summary> /// 获取当前应用程序指定CacheKey的Cache值 /// </summary> /// <param name="CacheKey"></param> /// 阅读全文
posted @ 2013-04-15 15:09 it草根 阅读(259) 评论(0) 推荐(0)
摘要:下面是asp.net中多个文件夹上传源代码,包括前台和后台ASPX 代码<%@ Page Language="C#" AutoEventWireup="true" CodeFile="MultiFileUpload.aspx.cs" Inherits="MultiFileUpload" %><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN""http://www.w3.org/TR/xhtml1 阅读全文
posted @ 2012-03-12 12:59 it草根 阅读(470) 评论(0) 推荐(0)
摘要:只能输入数字:"^[0-9]*$"。 只能输入n位的数字:"^\d{n}$"。 只能输入至少n位的数字:"^\d{n,}$"。 只能输入m~n位的数字:。"^\d{m,n}$" 只能输入零和非零开头的数字:"^(0|[1-9][0-9]*)$"。 只能输入有两位小数的正实数:"^[0-9]+(.[0-9]{2})?$"。 只能输入有1~3位小数的正实数:"^[0-9]+(.[0-9]{1,3})?$"。 只能输入非零的正整数:"^\+?[1-9] 阅读全文
posted @ 2012-03-12 12:58 it草根 阅读(125) 评论(0) 推荐(0)
摘要:asp.net里导出excel表方法汇总 1、由dataset生成public void CreateExcel(DataSet ds,string typeid,string FileName) { HttpResponse resp; resp = Page.Response; resp.ContentEncoding = System.Text.Encoding.GetEncoding("GB2312"); resp.AppendHeader("Content-Disposition", "attachment;filename=&quo 阅读全文
posted @ 2012-03-12 12:57 it草根 阅读(223) 评论(0) 推荐(0)