Solved

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

Posted on 2013-01-02
4
644 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

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Today is the age of broadband.  More and more people are going this route determined to experience the web and it’s multitude of services as quickly and painlessly as possible. Coupled with the move to broadband, people are experiencing the web via …
A quick way to get a menu to work on our website, is using the Menu control and assign it to a web.sitemap using SiteMapDataSource. Example of web.sitemap file: (CODE) Sample code to add to the page menu: (CODE) Running the application, we wi…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

830 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