摘要: 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草根 阅读(256) 评论(0) 推荐(0)
摘要: 1.绝对值 SQL:select abs(-1) value O:select abs(-1) value from dual 2.取整(大) S:select ceiling(-1.001) value O:select ceil(-1.001) value from dual 3.取整(小) S:select floor(-1.001) value O:select floor(-1.001) value from dual 4.取整(截取) S:select cast(-1.002 as int) value O:select trunc(-1.002) value from... 阅读全文
posted @ 2012-03-12 13:01 it草根 阅读(659) 评论(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草根 阅读(468) 评论(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草根 阅读(220) 评论(0) 推荐(0)
摘要: using System;using System.Data;using System.Configuration;using System.Collections;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Web.UI.HtmlControls;using System.Data.OleDb;using Excel = Microsoft. 阅读全文
posted @ 2011-03-16 15:37 it草根 阅读(3815) 评论(2) 推荐(0)