开发者

Where are aspx.cs and aspx.designer.cs

开发者 https://www.devze.com 2023-03-11 05:39 出处:网络
I have inherented a web site from someone who is not available any more.In the deployed folder I have Config.aspx there (please see the code).But I can not find the codebehind file.The config page wor

I have inherented a web site from someone who is not available any more. In the deployed folder I have Config.aspx there (please see the code). But I can not find the codebehind file. The config page works. Where can I find the .cs files?

Thanks

<%@ page language="C#" masterpagefile="~/Master/StaffPortal.master" autoeventwireup="true"
    inherits="Admin_Config" title="Configuration" codebehind="Config.aspx.cs" %>

<asp:content id="Content1" contentplaceholderid="PageBody" runat=开发者_StackOverflow"Server">
    <div style="width: 405px; height: 25px" class="GeneralCaption">
    Configuration Parameters
    </div>
    <asp:Table ID="Table" runat="server" Style="width:100%">
    </asp:Table>
    <asp:Button ID="OKButton" runat="server" CssClass="GeneralButton" Text="OK" OnClick="OKButton_Click" />
    <asp:Button ID="CancelButton" runat="server" CssClass="GeneralButton" Text="Cancel" OnClick="CancelButton_Click" />
</asp:content>


if the project is deployed then all .cs files are already compiled into .dll file in bin folder. You need to have the project source to access them.


If you cant find them anywhere and you need to get the cs files out of the DLL - here's how:

Get Reflector by redgate, install this add-in: http://www.denisbauer.com/NETTools/FileDisassembler.aspx

Drag the DLL into Reflector then dissemble it using Denis's add-in. All the code behind files will be extracted from the DLL, unfortunately comments will be missing.

UPDATE

These days I use the free tool ILSpy and you can simply save assemblies as projects - its a great way to convert entire projects to different languages.


If this is the published folder, the codebehind pages would have been compiled into a .dll in the bin folder. The only way to get the code behind would be to get the source project


When we publish a web application, the code behind files are compiled into dll's that are stored in a bin folder.

You have to get the Source files from the Developer.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号