Collecting ASP. NET errors

Source: Internet
Author: User

1. Exceeds the maximum request length.

Test the uploaded file code. The default value is ASP. Netallows users to upload 2 MB files. This error is generated when I upload a plug-in installation program popo.exe file to the local server.

References:

In Asp.net, the default size of the uploaded file is 4096 kb, that is, 4 M. However, you can change the data in Web. config.

<System. Web>
<! -- The maximum size of uploaded files is 8 Mb. -->
<Httpruntime maxrequestlength = "8192" usefullyqualifiedredirecturl = "true" executiontimeout = "100"/>
</System. Web>

At this time, it is an 8 M file. Of course, you can modify it more, But no matter whether it is changed to multiple metropolis, there is a limit. If the File Uploaded by the user is larger than this value, exceptions that cannot be caught by the program will occur, because they can be monitored only during running.

Generally, the more common method is to directly modify C:/Windows/Microsoft. net/framework/v1.1.4322/config directory machine. config File (the Framework version will be different, and the directory of the version you use will be entered), find httpruntime in this line to change the value of maxrequestlength to the ideal value, such as 8 m, then, enter 8192. In this way, any web project can upload files up to 8 Mb.

If you do not use third-party components but only use the built-in. NET functions, it seems that 10 MB is actually the peak value.

2. Insufficient Application Access Permissions

Select folder -- Right-click -- Property -- security option -- users (machine name/users), and you can fully control all users permissions.

Execute ASP. NET pages in Win2000 and WINXP. The default account is ASPnet, win2003, and network services.

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.