Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 2.0 > ASP.NET 2.0 Professional
Password Reminder
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
ASP.NET 2.0 Professional If you are an experienced ASP.NET programmer, this is the forum for your 2.0 questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Professional section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old August 23rd, 2007, 08:26 AM
Authorized User
Join Date: May 2007
Location: pune, maharashtra, India.
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Default Can we extend the precompiled & deployed applicati

I have precompiled my website application and also deployed it on the server
but if I extend the application in future. then should i precompile and deploy the whole
application again or is there any another way to do it.

Amol Chikurte
Amol Chikurte
  #2 (permalink)  
Old August 23rd, 2007, 09:28 AM
planoie's Avatar
Friend of Wrox
Points: 16,481, Level: 55
Points: 16,481, Level: 55 Points: 16,481, Level: 55 Points: 16,481, Level: 55
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Aug 2003
Location: Clifton Park, New York, USA.
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts

Simply changing the literal HTML of an ASPX or ASCX file doesn't require re-compiling if the full file is part of the site.

If you need to change some compiled code you can use what I call the "patch method":
- Take the original codebehind file and change the class name (for example change "mypage" to "mypage_patch"). This step is important because the runtime would get a class name ambiguity because the same class would also exist in the precompiled assembly.
- Change the @ Page directive to use the "Src" attribute instead of the "CodeFile" attribute. The value can remain the same.
- Change the @ Page directive "Inherits" attribute to the new class name from the first step. This changes the page to use the dynamically compiled class instead of the precompiled version in the assembly.
- Make the necessary changes to the codebehind files.
(Important note: When using VB, you might need to remove the namespace prefix in the "Inherits" attribute value. A VB project specifies a default namespace for the project and the individual .vb files don't include the namespace blocks around the code.)
- Deploy the changed ASPX/ASCX files along with the codebehind files.


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with Precompiled Usercontrols ramki16 ASP.NET 2.0 Professional 0 April 9th, 2008 04:21 AM
Deploy Changes in already deployed server khishores C# 2005 0 February 4th, 2008 05:37 PM
Publishing - Precompiled updatable site timType3 Visual Studio 2005 0 August 14th, 2006 09:31 AM
How to monitor Website Info from Windows Applicati Awsok General .NET 0 March 3rd, 2005 11:30 AM
How to Use Precompiled OBJ johan_yo Visual C++ 2 July 26th, 2003 02:23 PM

All times are GMT -4. The time now is 04:54 PM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.