随笔分类 -  C#

中文检索从程序查询后查询不出来数据。解决方式,连接字符串后增加Unicode=Ture;
摘要:系统部署后数据库sql语句查询也正常,跟踪的代码查询也正常,但是中文检索从程序查询后查询不出来数据。解决方式,连接字符串后增加Unicode=Ture; 阅读全文
posted @ 2015-11-05 10:50 wuzx-blog 阅读(226) 评论(0) 推荐(0)
C#后台 GPS坐标转化成百度坐标
摘要:protected void Page_Load(object sender, EventArgs e) { //获取当前纬度 string Latitude = "117.707677"; ... 阅读全文
posted @ 2015-10-12 15:28 wuzx-blog 阅读(2406) 评论(0) 推荐(0)
c#获取url请求的返回值,C#调用Url
摘要:/// /// 获取url的返回值 /// /// eg:http://m.weather.com.cn/atad/101010100.html public string GetInfo(string url) ... 阅读全文
posted @ 2015-10-12 15:25 wuzx-blog 阅读(1735) 评论(0) 推荐(0)
C# json字符串转为对象
摘要:方法一usingSystem.Web.Script.Serialization;stringss="{\"NewsCount\":\"3482\",\"NewsList\":[{\"Title\":\"成都建国“牵手起亚、爱心互助”成功举行\",\"Content\":\"...感恩而永恒5月16日... 阅读全文
posted @ 2015-10-12 15:21 wuzx-blog 阅读(265) 评论(0) 推荐(0)
jquery调用一般处理程序的多个方法
摘要:jquery调取方式:一般处理程序后台编写方法;/// /// GetTraceabilityJson 的摘要说明 /// public class GetTraceabilityJson : IHttpHandler { public void Proce... 阅读全文
posted @ 2015-04-30 09:48 wuzx-blog 阅读(1113) 评论(0) 推荐(0)
MVC 调取json 稍后整理
摘要:http://www.cnblogs.com/kissdodog/archive/2012/12/31/2841201.html 阅读全文
posted @ 2014-01-10 16:46 wuzx-blog 阅读(148) 评论(0) 推荐(0)
MVC4 日期格式转化解决
摘要:@Html.DisplayFor(modelItem => item.CreateDate.ToShortDateString())显示数据是转化失败,MVC不支持该方法。 解决办法如下: 在实体层使用DisplayFormat格式转化,如下 [Display(Name = "日期格式")] [... 阅读全文
posted @ 2014-01-10 10:01 wuzx-blog 阅读(362) 评论(0) 推荐(0)
Mvc4 HtmlHelper @Html用法大全
摘要:HtmlHelper用来在视图中呈现 HTML 控件。 以下列表显示了当前可用的一些 HTML 帮助器。本主题演示所列出的带有星号 (*) 的帮助器。 ActionLink- 链接到操作方法。 BeginForm* - 标记窗体的开头并链接到呈现该窗体的操作方法。 CheckBo... 阅读全文
posted @ 2013-12-25 15:04 wuzx-blog 阅读(798) 评论(0) 推荐(0)
Mvc4中的ViewData与ViewBag
摘要:在Asp.net Mvc 3和Mvc4 web应用程序中,我们会用到ViewData与ViewBag,对比一下: ViewData ViewBag 它是Key/Value字典集合 它是dynamic类型对像 从Asp.net MV... 阅读全文
posted @ 2013-12-25 11:09 wuzx-blog 阅读(1417) 评论(0) 推荐(0)
为Mvc4增加多个文件夹,添加域(Areas)区分Admin域和用户域
摘要:当一个项目中有前台页面和后台页面,即用户页面和管理员页面,.net mvc4 如何控制路由为:Admin/{controller}/{action}/{id}访问的是管理员(Admin)的域,而通过路由:{controller}/{action}/{id}则访问的是用户页面? 解决方案 .net ... 阅读全文
posted @ 2013-12-25 11:03 wuzx-blog 阅读(1359) 评论(0) 推荐(0)
(asp.net MVC学习)System.Web.Mvc.HtmlHelper学习及使用
摘要:1.使用HtmlHelper生成超链接: 2.使用HtmlHelper生成表单: 3.使用HtmlHelper根据路由规则生成表单: 4.使用HtmlHelper生成一个复选框: 复选框 5.使用HtmlHelper生成上拉列表框: 6.使用HtmlHelper生成隐藏域: ... 阅读全文
posted @ 2013-12-23 14:54 wuzx-blog 阅读(324) 评论(0) 推荐(0)
Entity FrameWork CodeFirst 代码优先(三)
摘要:摘抄 阅读全文
posted @ 2013-08-12 17:42 wuzx-blog 阅读(329) 评论(0) 推荐(0)
Entity FrameWork CodeFirst 代码优先(二)
摘要:摘抄 阅读全文
posted @ 2013-08-12 17:29 wuzx-blog 阅读(392) 评论(0) 推荐(0)
Entity FrameWork CodeFirst 代码优先(一)
摘要:摘抄 阅读全文
posted @ 2013-08-12 17:28 wuzx-blog 阅读(325) 评论(0) 推荐(0)
Razor视图引擎的基础语法
摘要:摘抄 阅读全文
posted @ 2013-08-12 15:17 wuzx-blog 阅读(228) 评论(0) 推荐(0)
Razor中的@helper 语法
摘要:摘抄 阅读全文
posted @ 2013-08-12 15:13 wuzx-blog 阅读(752) 评论(0) 推荐(0)
Entity FrameWork 取表中字段的最大值
摘要:int? max = (from t in context.Test select (int?)t.ID).Max(); int m = 0; if (!max.HasValue) ... 阅读全文
posted @ 2013-08-08 17:41 wuzx-blog 阅读(704) 评论(0) 推荐(1)