• C# split用法


     1string[] sss=txtQueryVal.Text.ToString().Split(new char[] {'-'});
     2
     3                    string year=sss[0].ToString();
     4                    string month=sss[1].ToString();
     5                    string day=sss[2].ToString();
     6
     7                    string selsql4="select * from OA_Worklog where Datepart(year,OA_Worklog_Day)='"+year+"'and Datepart(month,OA_W orklog_Day)='"+month+"'and Datepart(day,OA_Worklog_Day)='"+day+"'";
     8                    SqlDataAdapter sqlCom4=new SqlDataAdapter(selsql4,sqlCon);
     9                    DataSet ds=new DataSet();
    10                    sqlCom4.Fill(ds,"OA_Worklog");
    11                    DGrid_QueryResult.DataSource=ds.Tables["OA_Worklog"].DefaultView;
    12                    DGrid_QueryResult.DataKeyField="OA_Worklog_Id";
    13                    DGrid_QueryResult.DataBind();
  • 相关阅读:
    Eclipse 中使用 ctrl 无法追踪函数的问题
    AJAX跨域问题
    eclipse设置svn代理
    同步IO和异步IO
    阿里云配置redis
    Centos +django+nginx
    Centos 安装nginx
    django 给前端传递HTML内容
    django项目初探
    python邮件服务
  • 原文地址:https://www.cnblogs.com/shf/p/343338.html
Copyright © 2020-2023  润新知