• 博客园logo
  • 会员
  • 众包
  • 新闻
  • 博问
  • 闪存
  • 赞助商
  • HarmonyOS
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录
小香猪 工作室~~
————含泪播种的人一定能含笑收获 !!!

asp.net、 C#、 Sql Server、 html+css、 wpf、 wcf and so on

兢兢业业学技术 踏踏实实诚做人……
博客园    首页    新随笔    联系   管理    订阅  订阅
上一页 1 2 3 下一页
2010年11月22日
list<>操作
摘要: List<T>.Sort() // 排序T 2List<T>.Find() // 找出一個T 3List<T>.FindAll() //找出多個T 4List<T>.Exist() //判斷T是否存在view sourceprint?1lIST<Person> lstPerson=new List<>(Person);view... 阅读全文
posted @ 2010-11-22 09:56 xyp0605 阅读(149) 评论(0) 推荐(0)
2010年11月20日
创建表两个主键外键~~~
摘要: create table A( id int primary key not null, name nvarchar(20) not null, address varchar(50) not null)这个是主表(设置了一个主键)create table B( id int not null foreign key references A(id) on delete cascade, orde... 阅读全文
posted @ 2010-11-20 15:22 xyp0605 阅读(250) 评论(0) 推荐(1)
2010年11月12日
有关最近做的项目中用到的日期控件
摘要: 嗯,一般我用的日期控件(这个也是狼子做好的日期控件,然后我们可以拖过来就可以用了的)--NnllDate.ascx有三个快捷按钮 前一天 今天 后一天(或者也可以前一个月 本月 后一个月)嗯,下面是狼子在后台的代码:前一天DateTime dt=Convert.ToDateTime(NnllDate1.Text);//点击前一天的时候可以实现本天的前一天NnllDate1.Text=dt.AddD... 阅读全文
posted @ 2010-11-12 14:06 xyp0605 阅读(173) 评论(0) 推荐(0)
2010年9月20日
存储过程分页
摘要: CREATE proc w_Log_select@LogType int,@rowsCount int output,--符合条件的记录@pageSize int output, --每页要显示记录数@pageCount int output,--页码@pageIndex int output --第几页asdeclare @sql varchar(1000)set @pageSize =15se... 阅读全文
posted @ 2010-09-20 17:01 xyp0605 阅读(171) 评论(0) 推荐(0)
2010年9月10日
正则表达式
摘要: "^\d+$" //非负整数(正整数 + 0) "^[0-9]*[1-9][0-9]*$" //正整数 "^((-\d+)|(0+))$" //非正整数(负整数 + 0) "^-[0-9]*[1-9][0-9]*$" //负整数 "^-?\d+$" //整数 "^\d+(\.\d+)?$" //非负浮点数(正浮点数 + 0) "^(([0-9]+\.[0-9]*[1-9][0-9]*)|([0-9... 阅读全文
posted @ 2010-09-10 13:48 xyp0605 阅读(131) 评论(0) 推荐(0)
2010年8月10日
绑定数据
摘要: 要绑定gridview字段一般我习惯了像这样的 <asp:BoundField DataField="PlayerName" HeaderText="账号" />">可是这样要绑定这个字段不方便,但可以用 <asp:TemplateField HeaderText="是否成功" SortExpression="IsReturn">来代替后台可以写个方法public s... 阅读全文
posted @ 2010-08-10 11:15 xyp0605 阅读(149) 评论(0) 推荐(0)
2010年8月9日
循环累加 由for _foreach
摘要: for(int i =0;i<ds.tables[0].Rows.Count;i++){ string objmoney=ds.tables[0].Row[i]["returnmoney"].tostring(); string objreturn=ds.tables[0].Row[i]["isreturn"].tostring(); decimal decmoney=0; int intr... 阅读全文
posted @ 2010-08-09 17:42 xyp0605 阅读(376) 评论(0) 推荐(0)
连接数据库
摘要: 之前都是在页面里面直接写什么链接数据库的string sqlstr="server=. uid=sa ;pwd=123456 ;database=数据库名";sqlconnection conn=new sqlconnection();conn.open();然后改成在web.config里面写<appSettings><add key="constr" value="serve... 阅读全文
posted @ 2010-08-09 17:31 xyp0605 阅读(124) 评论(0) 推荐(0)
2010年7月16日
打印gridview 中的所有内容
摘要: 如果一个gridview 绑定了一写数据,我想把它打印出来的话,该怎么做呢?首先有一段时gridview的代码,在gridview的代码周围写一个id例如:<divid="PrintArea"><asp:GridViewClientIDMode="Static"ID="GV"runat="server"AutoGenerateColumns="False"><Colu... 阅读全文
posted @ 2010-07-16 15:35 xyp0605 阅读(410) 评论(0) 推荐(0)
2010年6月26日
连接数据库sql server 2005
摘要: 在连接数据库的时候,如果是比较小的项目的话,可能是直接写在连接的地方,而一般比较大一点的项目我们都是用三层架构写的我做的是三层的,用的是一个Common类库中的一个Sqlhelper中写的公共的调用数据库的类里面。在webconfig里面连接数据库的时候我们一般是用server=.;uid=sa;pwd=123456;database=连接的数据库名;可是这样使用的话,我在运行的时候出问题说什么连... 阅读全文
posted @ 2010-06-26 17:37 xyp0605 阅读(177) 评论(0) 推荐(0)
上一页 1 2 3 下一页
博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3