Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 1.0 and 1.1 > ASP.NET 1.0 and 1.1 Basics
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
ASP.NET 1.0 and 1.1 Basics ASP.NET discussion for users new to coding in ASP.NET 1.0 or 1.1. NOT for the older "classic" ASP 3 or the newer ASP.NET 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Basics 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 May 18th, 2007, 03:07 PM
Authorized User
 
Join Date: Oct 2006
Location: , , .
Posts: 10
Thanks: 0
Thanked 1 Time in 1 Post
Default what is debug directive for codebehind file?

I have an ASP.NET project. I can turn on debugging informations in the aspx files with a page directive like <%@ Debug="true" %>

If there are errors in the inline code in that aspx page, then the debugging messages help me find them. But most of the code lives in a codebehind file, which is also specified in the page directive <%@ src="file.cs" %>. I want to have the same debugging information to find errors in my codebehind file. I can't put the page directive in the C# file. Turning on debugging for the entire application works, but I would like to be able to do it on a file-by-file basis.

Do you know how?

Thanks in advance.

  #2 (permalink)  
Old May 18th, 2007, 03:42 PM
Wrox Author
Points: 13,255, Level: 49
Points: 13,255, Level: 49 Points: 13,255, Level: 49 Points: 13,255, Level: 49
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2005
Location: Ohio, USA
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Are you using visual studio?

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
================================================== =========
Technical Editor for: Professional Search Engine Optimization with ASP.NET
http://www.wiley.com/WileyCDA/WileyT...470131470.html
================================================== =========
Why can't Programmers, program??
http://www.codinghorror.com/blog/archives/000781.html
================================================== =========
  #3 (permalink)  
Old May 18th, 2007, 03:59 PM
Authorized User
 
Join Date: Oct 2006
Location: , , .
Posts: 10
Thanks: 0
Thanked 1 Time in 1 Post
Default

I'm not using visual studio.

  #4 (permalink)  
Old May 18th, 2007, 04:18 PM
Wrox Author
Points: 13,255, Level: 49
Points: 13,255, Level: 49 Points: 13,255, Level: 49 Points: 13,255, Level: 49
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2005
Location: Ohio, USA
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Read this:
http://samples.gotdotnet.com/quickst...bugcomsdk.aspx

Also, you should know, this is an "all or nothing" situation. You can not have one page that runs without Debugging and one pages the does in the same assembly.

Also, ONLY use debugging in a development environment as it requires far more overhead from the server and can cause preformance problems in general. Always move applications to a production server with debugging turned off.

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
================================================== =========
Technical Editor for: Professional Search Engine Optimization with ASP.NET
http://www.wiley.com/WileyCDA/WileyT...470131470.html
================================================== =========
Why can't Programmers, program??
http://www.codinghorror.com/blog/archives/000781.html
================================================== =========
  #5 (permalink)  
Old May 21st, 2007, 06:38 PM
Authorized User
 
Join Date: Oct 2006
Location: , , .
Posts: 10
Thanks: 0
Thanked 1 Time in 1 Post
Default

I don't know what it means for two pages to be "in the same assembly". Could you elaborate?

It certainly _is_ possible to have two pages next to each other, one with debugging turned on, one without, if they use inline asp code (inside <script runat="server"> tags). I don't know if this contradicts what you said though, since I don't know whether these pages are in the same assembly.

So the upshot is this: you can't both use codebehind/codefiles and also have per file debugging policy at the same time. Have I understood that correctly?

Thanks

 


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
cant locate file during debug cprogrammer C++ Programming 0 October 10th, 2007 10:38 PM
Making an Alteration to an VB Codebehind file Nostromo77 ASP.NET 2.0 Basics 4 April 24th, 2007 08:11 PM
Regex within a DirectoryMatch Directive someUser BOOK: Beginning Regular Expressions 1 June 6th, 2006 04:53 AM
CodeBehind for .ascx file isn't working lcsgeek General .NET 1 January 21st, 2005 03:50 PM
#exec server directive vitanza BOOK: Beginning ASP 3.0 1 July 11th, 2003 09:33 AM



All times are GMT -4. The time now is 04:09 AM.


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