Solved

Getting http: Status 401: Unauthorized on First Debug, but not the Second, Third, Fourth  Debug.

Posted on 2013-01-02
4
637 Views
Last Modified: 2013-01-09
Hi Everyone,

I am getting a http: Status 401: Unauthorized error when I first load my web application and debug.  When I stop debugging and do another Debug, my application loads with no errors appearing.  What is happening?  I stop debugging and do another third debug the application continues to load normally with no errors.

When I close out VS 2005 and come back in the first time and load my application, I get the http: Status 401: Unauthorized each time.  I then stop debugging and debug again, my application works and loads normally.

Maybe its my computer and the VS 2005 on my machine or IS Settings.  Please find the authentication setting I have on my machine attached.

Strange, I do not understand what is happening.

Also, noticed after minimizing the application and then coming back after break and maximizing the application and then trying to debug again, the 401 Status Error appears again on the debug.
Status-401Capture.PNG
SettingsChanged01022013Capture.PNG
0
Comment
Question by:jjc9809
  • 2
4 Comments
 
LVL 23

Assisted Solution

by:Roopesh Reddy
Roopesh Reddy earned 250 total points
ID: 38740593
0
 
LVL 25

Accepted Solution

by:
apeter earned 250 total points
ID: 38741968
Looks like you have a web service within same webproject. Also you are calling the web service on the On_start of the application , Hence the problem for the first time.  From the second time since the intermediate IIS is already available/loaded it is for working fine.

So when ever the Appdomain is unloaded or iisreset, it ill fail..

You have two of fixing this.
1. Move the Web service into a separate site.So this is independent or started before you web project.
2. Don't call the web service inside "Application_start" event.....maybe inside a aspx page. like login page etc
0
 
LVL 23

Expert Comment

by:Roopesh Reddy
ID: 38758746
Hi,

Is this issue solved? Any Updates?
0
 

Author Closing Comment

by:jjc9809
ID: 38758883
I found the authentication properties in IIS 6 were disabled.  Also, we had some permission issues that still have not be resolved.  I appreciate your help.
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Creating an analog clock UserControl seems fairly straight forward.  It is, after all, essentially just a circle with several lines in it!  Two common approaches for rendering an analog clock typically involve either manually calculating points with…
Here I am going to explain creating proxies at runtime for WCF Service. So basically we use to generate proxies using Add Service Reference and then giving the Url of the WCF service then generate proxy files at client side. Ok, what if something ge…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now