How to save C# class generated from ASPX page?

D

derek

I am using Visual Studio .NET Professional (first version) and am
trying to view
the generated C# file that is created from an ASP.NET (.aspx) page when
its first
requested. I can see where its being placed but it must be removed
after the
MSIL code is generated for it. Do you know any way to configure
vstudio to keep
the generated class files around so I can view them? I would like to
analyze the
generated code.. especially when I get an error in the page.

Thanks,
Derek

ps. this is where it says the generated files are placed prior to
compilation:
C:\WINDOWS\Microsoft.NET\Framework\v2.0.40607\Temporary ASP.NET
Files\315c01\83249c80\3856d1b7
 
A

Anders Norås [MCAD]

I am using Visual Studio .NET Professional (first version) and am
trying to view
the generated C# file that is created from an ASP.NET (.aspx) page when
its first
requested. I can see where its being placed but it must be removed
after the
MSIL code is generated for it. Do you know any way to configure
vstudio to keep
the generated class files around so I can view them? I would like to
analyze the
generated code.. especially when I get an error in the page.

Enable debugging by including a <%@ Page Debug="true" %> directive in the
ASPX files or a <compilation debug="true"> statement in web.config. Then
look for the generated CS files in the temporary folder (eg. 315c01`..) in
\%SystemRoot%\Microsoft.NET\Framework\v1.0.nnnn\Temporary ASP.NET Files.

Anders Norås
http://dotnetjunkies.com/weblog/anoras/
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,013
Latest member
KatriceSwa

Latest Threads

Top