Several aspects to improve ASP. NET Efficiency

Source: Internet
Author: User
1. Avoid unnecessary operations
2. disable unnecessary session Status
3. Do not use Server Control when server control is unnecessary.
4. Disable viewstate if not necessary
5. Do not use exception Control ProgramProcess
Try {
Result = 100/num;
}
Catch (exception e ){
Result = 0;
}
6. Do not use dataset to replace dataset with sqldatareader for read-only data access
7. Disable the debug mode of ASP. NET. The debug mode in Web. config must be false, and the DLL file compilation must be generated into a release version.
8. Use ASP. net output cache to buffer data
9. buffer a large number of rarely updated data
9. Try to use stored procedure data for access
10. Static pages are not dynamic.
11. The effects implemented with JS are implemented with JS, and the result of rollback can be reduced when implemented on the client.
12. Switch to server. Transfer without response. Direct
13. Do not open or create an ADO. Net object during one use. Try to use a connection, command, or datareader. Remember to close or release the object immediately when you no longer call the database data.
14. How many data sets are required to avoid non-pagination of fields
15. Do not use dataset or DataGrid.
16. Run on win2003 Enterprise Edition
========================================================== =

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.