I'm new to asp.net - previous experience is in .asp.
I've been asked to take over development of a web-site - no problem all I need is the ftp details and download the files.
But not this time - as the site is developed in asp.net.
There is a bin directory containing files 'Activity.dll' and 'Activity.pdb'.
Am I right in thinking that this has been developed in vs.net?
And that in order to take on development I'm going to need a copy of vs studio.net and get hold of all the project files from the previous developer?
Has anyone had any experience of not being able to get hold of the necessary pre-compiled files when taking over an asp.net application?
Thankyou
DanYes, it looks like VS generated files (*.pdb holds debugger information). It would be nice to receive source code of site to work on it. Application can contain two kinds of files:
1. HTML resources (*.aspx, *.ascx, *.html, etc.) - you can copy those from site.
2. Codebehind and serverside code files (*.vb, *.cs, etc.) - those should not exist on production server
hmmm - does this mean that I am unable to simply download the files via FTP and transfer them to a different server.
For instance on the top of one .aspx file you have the following code:
<%@. Page language="c#" Codebehind="step2_activity.aspx.cs" AutoEventWireup="false" Inherits="Activity.step2_activity" %>
I was unable to find a .cs file and am not sure where the location of the file the inherits command is set to.
I've got VS Studio.net 2003 on order so will soon be able to compile my own applications but would appreciate any help or links on ensuring I get all the necessary files when taking over a site.
ThankYou
Dan
You can transfer site to different server, but you do not necessary can recompile/alter it. You have to find *.cs files (if any code was added to them). VS will create empty classes for you will not supply those.
So you're saying that the code behind files don't need to be on the production server? I assume the dll in the Bin folder contains all the code for every page then. Do you have a link that outlines all the crucial files the production web server needs?
Hi,
I don't know of a link to a certain article but you can deploy the built assembly in the /bin subfolder and then only copy the .aspx & .ascx and global.asax, web.config, any images, .js script files and .css style sheets.
Grz, Kris.
Page.aspx is the presentation page (HTML, layout, etc..)
Page.cs is the c# code
Activity.dll is the executable created from the code in page.cs (and all the other .cs files)
Activity.pdb is the debugger file - which definitely shouldn't be on a production server - if it's there the application is probably still running in debug mode, yuck!
Without access to Page.cs and the other .cs files, maintaining this site is going to be impossible unless you're only responsible for cosmetic (design) changes.
> Without access to Page.cs and the other .cs files, maintaining this site is going to be impossible
Not entirely true.
You can use a tool such asReflector for .NET, that will convert the MSIL in the .dll back into C# or VB.NET.
You'll lose any comments, but you can effectively get back the original source code.
Thanks everyone - it's an interesting difference between asp.net and .asp
With .asp all the code was uncompiled. So if you could get hold of all the site files then you could take over development easily enough.
But with .net all you get is the compiled .dll . If the previous developer decides not to release the appropriate .cs files then its almost as if you have to start from scratch.
0 comments:
Post a Comment