asp.net 2.0 Publishing issues

Source: Internet
Author: User
Tags http request iis metabase
Asp.net| problem

Yesterday in a QQ group have a friend asked, asp.net2.0 how to publish (compile) The program, build the DLL.
However, the Vwd2005 Express we obtained from MS does not support publishing DLL generation.
You can use Aspnet_compiler.exe to publish our project.

Yesterday also from Ms up and down a. NET Framework 2.0 Software Development Kit (SDK) Beta 2 x86
Download Address http://www.microsoft.com/downloads/details.aspx?familyid=41070791-8912-4f94-ac46-7ce0e386d5c9& displaylang=en
After installation, select this item by starting menu/program/mrcrosoft. NET framwoks SDK 2.0/sdk command prompt
The DOS interface path is directly C:\Program files\microsoft_visual_studio_8\sdk\v2.0>

In a way, we can use Aspnet_compiler.exe.
What if you use this command? Enter Aspnet_compiler-? Carriage return
Parameter use is out and still Chinese, more convenient

C:\Program Files\microsoft_visual_studio_8\sdk\v2.0>aspnet_compiler-?
Utility to precompile the asp.net application
Copyright (C) Microsoft Corporation. All rights reserved.

Usage:
Aspnet_compiler [-?] [M MetabasePath |-v VirtualPath [P Physicaldir]]
[[u] [f] [-d] TargetDir] [-c] [-fixednames]
[-keyfile File |-keycontainer container [-APTCA] [-delaysign]]

-? Print this help text.
The full IIS metabase path for the-m application. This switch cannot be combined with the-V or-p switch.
-V The virtual path (for example, "/myapp") of the application to be compiled. If-p is specified, use the
The physical path locates the application. Otherwise, use the IIS
Metabase and assumes that the application is located at the default site (under "/lm/w3svc/1/root"). This
The switch cannot be combined with the-m switch.
-P The physical path of the application to be compiled. If-P is missing, the IIS metabase is used to locate this
Application. This switch must be combined with-V.
-U if specified, the precompiled application is updatable.
-F Overwrite the target directory if it already exists. Existing content will be lost.
-D If you specify this option, debug information will be emitted during compilation.
TargetDir the physical path to which the application will be compiled. If not specified, the application is precompiled in-place.
-C rebuilds the entire precompiled application if specified. Any previously compiled components will
Be recompiled. In the specified TargetDir
, this option is always enabled.
-keyfile the physical path of the strong name key file.
-keycontainer Specifies the strong name key container.
-APTCA if specified, a strong-named assembly will allow partially trusted callers.
-delaysign if specified, the assembly is not fully signed after it was created.
-fixednames if specified, the compiled assembly will have a fixed name.
-nologo suppresses compiler copyright messages.

Example:

The following two commands are equivalent and rely on the IIS metabase. The compiled application is deployed to C:\MyTarget:
Aspnet_compiler-m/lm/w3svc/1/root/myapp C:\MyTarget
Aspnet_compiler-v/myapp C:\MyTarget

The following command compiles the application/myapp in place. This way, when you send an HTTP request to it, no compilation is required:
Aspnet_compiler-v/myapp

The following command does not * rely on the IIS metabase because it explicitly specifies the physical source directory of the application:
Aspnet_compiler-v/myapp-p C:\myapp C:\MyTarget


C:\Program files\microsoft_visual_studio_8\sdk\v2.0>




Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.