.NET Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 



Go Back   Dev Articles Community ForumsProgramming.NET Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old April 6th, 2002, 01:58 PM
ckchin ckchin is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Posts: 52 ckchin User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 16
Question ASP.net and web.config error

I tried to test run my first asp.net page and found the following error. I hope that anyone of you can help me out. Thanks in advance.

When try to run the ASP.net page, I always faced trouble of Configuration error, as follows:
Code:
Server Error in '/' Application. 
---------------------------------------- 

Configuration Error 
Description: An error occurred during the processing of a configuration 
file required to service this request. Please review the specific error 
details below and modify your configuration file appropriately. 

Parser Error Message: It is an error to use a section registered as 
allowDefinition='MachineToApplication' beyond application level. This 
error can be caused by a virtual directory not being configured as an 
application in IIS. 

Source Error: 


Line 35: "Passport" and "None" 
Line 36: --> 
Line 37: <authentication mode="None" /> 
Line 38: 
Line 39: <!-- APPLICATION-LEVEL TRACE LOGGING 


Source File: c:\inetpub\wwwroot\cc\bookstore\csharp\web.config Line: 37 

----------------------------------------
Version Information: Microsoft .NET Framework Version:1.0.3705.0; ASP.NET 
Version:1.0.3705.0 


What is the possible error?

I tried to change the authentication mode form "None" to "Forms", it does not fixes the error.

Just for information. I did face this similar problem when I tried to test run certain asp.net script available at the ASP.NET QuickStart Tutorial come with the VS.net.

BUT, I can run the sample script of asp.net job site from the book ASP.NET UNLEASHED by Stephen Walther.

I really do not undertstand the reason. I read through and found out that possibility that it relates to machine.config file??? Is it?

Help needed. Thanks in advance.


__________________
Regards,

ckchin

Reply With Quote
  #2  
Old April 7th, 2002, 08:24 PM
mytch mytch is offline
Dev Articles Novice (500 - 999 posts)
 
Join Date: Apr 2002
Location: Sydney, Australia
Posts: 588 mytch User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 16
Hey,
What operating system are you running .NET on? Windows 2000? Try removing the virtual dir and moving the script to your base web dir in IIS...it might fix the prob.

Reply With Quote
  #3  
Old April 8th, 2002, 03:58 AM
James Yang James Yang is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Location: Atlanta, Georgia
Posts: 284 James Yang User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 m 45 sec
Reputation Power: 16
Send a message via ICQ to James Yang
my guess is that you are creating a directory in the wwwroot using explorer...


u should always use IIS to create virtual directory and make it a web "application".

its easy to fix open your IIS MMC and open the web site node, and you should see your directory. right click then properties and then you will see a command button labeled "create application". Click on that and click ok... now try


the cause of that error you are having is due to web.config file. You can't have it in a folder..it has to be a web application

hope this helps
__________________
Regards,

James Yang
.NET Developer / Network Engineer
MCSE, MCDBA, MCSA, CCNA

http://www.yellowpin.com/
http://www.opentechsupport.com/

Last edited by James Yang : April 8th, 2002 at 04:03 AM.

Reply With Quote
  #4  
Old April 8th, 2002, 06:17 AM
mytch mytch is offline
Dev Articles Novice (500 - 999 posts)
 
Join Date: Apr 2002
Location: Sydney, Australia
Posts: 588 mytch User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 16
ahhh james, you joined up.. hey keep up the posting my friend.

Reply With Quote
  #5  
Old April 8th, 2002, 06:57 AM
ckchin ckchin is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Posts: 52 ckchin User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 16
I solved the problem, and it's right what James Yang said.

Actually, there is nothing wrong with the web.config and the machin.config files.

I faced the error because I use EditPlus to run the script. I suppose test the script with the url of http://localhost/bookstore/ BUT when I always test it using EditPlus, the test url is http://localhost/codecharge/bookstore (I place the bookstore folder/files like this c:\Inetpub\wwwroot\codecharge\bookstore) which is not the virtual directory setting. What a silly mistake I've made.

Reply With Quote
  #6  
Old March 16th, 2004, 05:02 PM
halewilson halewilson is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Mar 2004
Posts: 1 halewilson User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Question

Quote:
Originally Posted by James Yang
my guess is that you are creating a directory in the wwwroot using explorer...


u should always use IIS to create virtual directory and make it a web "application".

its easy to fix open your IIS MMC and open the web site node, and you should see your directory. right click then properties and then you will see a command button labeled "create application". Click on that and click ok... now try


the cause of that error you are having is due to web.config file. You can't have it in a folder..it has to be a web application

hope this helps

-------------------------------------------------------------------------------------------------------------------------------------------
Hello,
I'm new at this. Where is the web.config supposed to be located? Directly within the "application" folder? Also, what if I have multiple copies of the "web.config" file within the applications in multiple directories?

Thanks so much
halewilson

Reply With Quote
  #7  
Old March 19th, 2004, 04:11 AM
argeam argeam is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Mar 2004
Posts: 6 argeam User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
sorry, i'm totally new to vs.net
can someone please tell me where can i control the IIS or even change anything to IIS cause i've been through many forums and most of it mention IIS.

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgramming.NET Development > ASP.net and web.config error


Developer Shed Advertisers and Affiliates


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.

© 2003-2018 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap