actually i need the maxRequestLength
value of the httpRuntime
section in web.config to check if a postedfile's size is greater. What's the best way to read it?
Thank you in advance.
actually i need the maxRequestLength
value of the httpRuntime
section in web.config to check if a postedfile's size is greater. What's the best way to read it?
Thank you in advance.
You can try something like
you can then get
section.MaxRequestLength
On load of your page set the max file size to a client side variable and check it on a client event because if you request the server to check it obviously it will error out before it gets to your validation.