Using a Text Editor to Develop and Deploy an ASP.NET Web Application
page 5 of 8
by Andrew Mooney
Average Rating: 
Views (Total / Last 10 Days): 36965/ 90

Compiling Our Sample Application

Now that we have created our application the next step is to compile it. I will cover two ways to pre-compile your web application in place using the ASP.NET command line compiler aspnet_compiler.exe. The first is to use a batch file. And the second makes use of Crimson Editor's ability to execute external programs with arguments. Listing 4 shows what the pre-compile batch file looks like.

Listing 4 - Make.bat used to pre-compile our web application

C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_compiler.exe -v /WebApp1

To set this up in CrimsonEditor, select Conf. User Tools from the Tools menu. And in the Preferences dialog box fill in the fields for the first User Tool using the following and also take a look at Image 1 below.

Menu Text: Compile ASP.NET - WebApp1

Command: C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_compiler.exe

Argument: -v /WebApp1

Initial Dir:

Hot Key: None

Close on exit: yes

Capture Output: yes

Use short file names: no

Save before execute: yes

Figure 1 - Setting up a User Tool to execute the ASP.NET compiler in Crimson Editor

If you are using the batch file method, just double click on it to run it. A command window will open and show the compiler output. If there are no errors displayed, you have successfully pre-compiled your web application.

With Crimson Editor you can select the User Tool we created from the Tools menu or use the Ctrl+1 shortcut. When activating this command,an output window will appear inside Crimson Editor instead of a command window. If no errors are shown the final output should read: "Terminated with exit code 0." This means that the application successfully pre-compiled.

A batch file can also be used within Crimson Editor, just right click on the file and select the Shell Execute command from the popup menu.

View Entire Article

User Comments

No comments posted yet.

Product Spotlight
Product Spotlight 

Community Advice: ASP | SQL | XML | Regular Expressions | Windows

©Copyright 1998-2024  |  Page Processed at 2024-05-27 9:47:31 AM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search