Get Max Request length from web.config

By Nitin

For retrieving maxrequest length from web.config use following function:

public int GetMaxLength()
{
HttpRuntimeSection httpRuntime =
(HttpRuntimeSection)ConfigurationManager.GetSection("system.web/httpRuntime");
return httpRuntime.MaxRequestLength;
}

Tags: , ,

तुमचा अभिप्राय नोंदवा