可以使用后台代码(code-behind)特性,把页面分离成两个文件,一个文件包含表现内容,另一个文件称为后台代码文件(code-behind),包含所有的应用程序逻辑。
基于92个网页-相关网页
现在已经准备好在客户端使用所有后台代码创建一个使用Dojo的UI。
Now you are ready to use all of this back-end code on the client to create a UI using Dojo.
然后VS就会自动地在我们的后台代码类文件中创建一个占位的事件处理函数实现。
VS will then automatically create a stub event handler implementation in our code-behind class file. We can use this event handler to update the Button's content with a new message when it is clicked.
在绝大多数情况下你不需要在后台代码中做任何事情,因为视图模型负责提供命令并连接视图和控制器。
In virtually all cases you shouldn't need to do anything in the code behind because the ViewModel takes care of providing the commands and linking between the view and the controller.
应用推荐