1、ViewData对象 ViewBagData是一种字典集合数据同时属于视图基类和控制器基类的属性。 实例: //控制器public class HomeController:Controller{ public ActionResult Index() { ...
分类:
Web程序 时间:
2014-06-19 06:48:39
阅读次数:
402
监听下载完成:
要想在下载完成后收到一个通知,需要注册一个Receiver来接收ACTION_DOWLOAD_COMPLETE广播。它将包含一个EXTRA_DOWNLOAD_ID extra,其中包含了已经完成下载的引用ID:
public void funclick(View view){
String serviceString = Context.DOWNLOAD_SERVICE;...
分类:
移动开发 时间:
2014-06-15 15:32:44
阅读次数:
618
这一章我们通过MediaPlayerService的注冊来说明怎样在Native层通过binder向ServiceManager注冊一个service,以及client怎样通过binder向ServiceManager获得一个service,并调用这个Service的方法。Native Servic...
分类:
移动开发 时间:
2014-06-15 13:15:36
阅读次数:
345
问题1:View层如何向Controller的Action传递Model数据?在View中,可以使用Form表单进行模型数据的提交,同样的,我们需要关联提交数据的类型,则需要在View中使用@model + 数据类型不同的是,此时Model属性为null,而且Model是一个只读属性,我们不能使用它...
分类:
其他好文 时间:
2014-06-15 13:10:18
阅读次数:
275
1 #encoding=UTF-8 2 # Configuration files must begin with a line specifying the encoding 3 # of the the file. 4 5 #***************************...
分类:
移动开发 时间:
2014-06-15 12:50:20
阅读次数:
619
首先,MVC和三层架构,是不一样的。 三层架构中,DAL(数据访问层)、BLL(业务逻辑层)、WEB层各司其职,意在职责分离。 MVC是 Model-View-Controller,严格说这三个加起来以后才是三层架构中的WEB层,也就是说,MVC把三层架构中的WEB层再度进行了分化,分成了控制器.....
分类:
Web程序 时间:
2014-06-15 11:10:22
阅读次数:
296
首先,我们在Model层中添加一个Person类。 namespace MVCTest.Models{ public class Person { public string IdCard { get; set; } public string Name { get; set; } public s...
分类:
其他好文 时间:
2014-06-15 10:44:24
阅读次数:
687
Eclipse :Version: Juno Service Release 2GrEclipse plugins:http://dist.springsource.org/release/GRECLIPSE/e4.2/本次安装了两个:其它的按提示操作即可安装好后创建一个Groovy Project...
分类:
系统相关 时间:
2014-06-15 10:40:17
阅读次数:
321
原地址:http://www.haogongju.net/art/25919361.The AnimationClip 'cube1_anim' used by the Animation component 'Cube1' must be marked as Legacy.解决方法:1. 点击“A...
分类:
其他好文 时间:
2014-06-15 09:43:53
阅读次数:
340
android 2.3中引入了Download manager,作为一个service来优化长时间下载操作的处理。Download Manager通过处理HTTP链接、监控链接的变化和系统重新启动来确保每一次下载都能成功。
下载文件;
public void funclick(View view){
String serviceString = Context.DOWNLOAD_SERV...
分类:
移动开发 时间:
2014-06-14 14:06:25
阅读次数:
233