01 February, 2012

How to find pen drive hidden folder

Sometimes due to virus attack, our pen drive data is hidden.  We think, all folders are deleted. So, check first before you format your Usb otherwise you will lose your data forever.  Sometimes hidden files are not displayed even if you "Show hidden files and folders" in the Folders Options. To find hidden folder in your pen drive. Just run the following command in your command window.
attrib -h -r -s /s /d g:\*.*
For accurate command just copy the above command and pest it. Here g: is considered your pen drive.  Replace g by your pen drive “drive letter”

23 January, 2012

Error: Sys.WebForms.PageRequestManagerTimeoutException The server request timed out


Few days ago I found an error when tried to export about 500 reports to pdf.  The error is Sys.WebForms.PageRequestManagerTimeoutException The server request timed out. This is not found as exception. It is found on run time as javascript error.  I was working on Ajax Control tool kit 3.5. It is occurred because export operation of 500 reports to pdf were relatively long time than default
AsyncPostBackTimeOut.
How to solve this problem?
AsyncPostBackTimeOut is a property of ScriptManager of Ajax. You can change time out length. To solve this problem I have increased the time out of AsyncPostBackTimeOut property.

For example, for exporting 100 pdf I need 20 minutes. So, I will use maximum time out limit 20 minutes which is exactly 1200 seconds. My code is like below.

<asp:ScriptManager ID="ScriptManager1" runat="server" AsyncPostBackTimeOut="1200" >
asp:ScriptManager> 

**The default value of the AsyncPostBackTimeOut property is 90 seconds.
For long time running method (Suppose a method will run for more than 90 seconds), you should use web service by setting timeout (number of seconds) of that web method by Javascript.

Error: This application was precompiled with personalization turned off


Some days ago I have deployed one of my asp.net applications in Windows 2003 server. After deploying I could not browse any pages. I was getting the following errors – 

This application was precompiled with personalization turned off, but it appears to have been turned on after the precompilation, which is not supported.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Web.HttpException: This application was precompiled with personalization turned off, but it appears to have been turned on after the precompilation, which is not supported.

I did not include Source Error and Stack Trace here. So, what is the solution of the problem?
Yea! I have solved the problem by adding  the following snippet in web config.
               
It works fine.
If you find same problem, try to solve the problem this way.