日期:2014-05-20 浏览次数:20886 次
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 Microsoft.Office.Interop.Owc11;
public partial class pic : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack && Request.QueryString["s"] != null && Request.QueryString["e"] != null)
{
string file;
DateTime s = DateTime.Parse(Request.QueryString["s"]);
DateTime et = DateTime.Parse(Request.QueryString["e"]);
string x = "";
string y = "";
string danwei = "时";
string sql = "";
int r = ((TimeSpan)(et - s)).Days;
//Response.Write(r);
//Response.Write("<br />");
if (r >= 365)
{
sql = "select datepart(yyyy,regtime) d,count(*) c from t_user where regtime between '{0}' and '{1}' group by datepart(yyyy,regtime) order by d";
danwei = "年";
}
else if (r >= 30)
{