在 asp.net 中使用 c# 预编译的网站中缺少 .cs 文件
我需要更改某些 asp.net 应用程序的代码,但该应用程序缺少 .cs 文件,只有 .aspx 文件。当我在谷歌中阅读时,我了解到该应用程序是一个预编译的网站。我对它不太熟悉,所以问题是,我能否以某种方式检索该应用程序的代码隐藏 .cs 文件,因为我需要更改那里的一些功能。当然有办法我可以访问它们或以某种方式检索它们吗?
提前致谢,
格雷格
I need to change the code of some asp.net application but the application is missing its .cs files, there are only .aspx files. As I read in google, I understand that the application is a precompiled website. I am not too familiar with it so the question is, can I somehow retrieve the code-behind .cs files of this application because I need to change some functions there. Surely there is a way I can access them or retrieve them somehow?
Thanks in advance,
Greg
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
如果您有预编译的网站,您将无法访问原始的 .cs 文件。它们被编译成程序集,您可以在 bin 文件夹中找到它们。如果您无法从某处获取原始 .cs 文件;那么你可以尝试使用 Reflector 来阅读代码。请记住,您通过 Reflector 看到的将是等效代码,而不是原始代码。
If you have a precompiled website, you will not be able to access the original .cs files. They are compiled into assemblies, that you will find in the bin folder. If you cannot get the original .cs files from somewhere; then you can try using Reflector for reading the code. Just keep in mind that what you are seeing through Reflector will be equivalent code, not the original code.
如果网站的代码被编译成 DLL,并且该 DLL 是用 C# 或 VB.NET 编写的,则您可能可以反编译该 DLL。你是这个意思吗?
编辑: @driis 给出了我正在考虑的 Reflector 的链接。当我丢失一些代码时我用过它,它有效。
If the website's code was compiled into a DLL, and that DLL was written in C# or VB.NET, you can probably decompile the DLL. Is that what you mean?
Edit: @driis gives the link to Reflector that I was thinking of. I've used it when I lost some code, it works.