本文介绍了是否有相当于 Webforms 的 MvcBuildViews?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有等同于 Webforms 的 MvcBuildViews?

Is there an equivalent to MvcBuildViews for webforms?

推荐答案

没有

另一种方法是向 Visual Studio 项目添加构建后操作并让它运行 aspnet_compiler.exe 以就地编译应用程序".

An alternative is to add a postbuild action to the visual studio project and have it run the aspnet_compiler.exe to "compile an application in place".

就地编译应用程序

ASP.NET 编译工具可以就地编译应用程序,即是,它模仿了制作的行为对应用程序的多个请求,从而导致定期编译.预编译站点的用户不会遇到编译造成的延迟第一次请求时的页面.

The ASP.NET Compilation tool can compile an application in place, that is, it mimics the behavior of making multiple requests to the application, thus causing regular compilation. Users of a precompiled site will not experience a delay caused by compiling the page on first request.

请注意,如果您使用的是模拟帐户,既是帐户并且登录用户帐户必须具有对目标的写访问权限预编译成功.

Note that if you are using an impersonated account, both the account and the logon user account must have write access to the target for precompilation to succeed.

当您就地预编译站点时,以下项目适用:

When you precompile a site in place, the following items apply:

  • 该网站保留其文件和目录结构.

  • The site retains its files and directory structure.

你必须有所有的编译器网站使用的编程语言在服务器上.

You must have compilers for all programming languages used by the site on the server.

如果任何文件编译失败,整个站点编译失败.

If any file fails compilation, the entire site fails compilation.

你也可以重新编译一个应用程序添加新源文件后就位到它.该工具只编译新的或更改的文件,除非您包括-c 选项.

You can also recompile an application in place after adding new source files to it. The tool compiles only the new or changed files unless you include the -c option.

这篇关于是否有相当于 Webforms 的 MvcBuildViews?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-01 03:54