Skip to main content

Posts

Showing posts from March, 2007

Autocomplete features of ASP.NET

Most of us would be very much familiar with "Autocomplete" feature of various browsers. After turning on that feature if you try filling any textboxes the browser provides you with the values which you have already typed in that field before. What if the "autocomplete" feature is turned ON in the end users browser but you don't want the data to be catched by the browser? Its quite simple. All we need to do is make use of the attribute "autocomplete" within the pages form tag. Example 1: Disabling Autocomplete for the whole form 1. Create a sample web form and replace that default form tag with the code snippet below <form id="form1" runat="server" autocomplete="off"> <asp:TextBox ID="txtOne" runat=server></asp:TextBox> <asp:TextBox id="txtTwo" runat="server" ></asp:TextBox> <asp:Button ID="btnGo" runat="server" Text="Submit" />

Restarting a remote computer via Remote Desktop ...

If you want to restart a computer which you have connected via Windows Remote Desktop do this. Start >> Run >> shutdown -r -f The machine would be restarted after 30 seconds automatically There are lots of other options available with shutdown command. You can view all the available options by typing " shutdown /? " in the command window.

Server Application Unavailable

Error Message: The web application you are attempting to access on this web server is currently unavailable. Please hit the "Refresh" button in your web browser to retry your request. Administrator Note: An error message detailing the cause of this specific request failure can be found in the system event log of the web server. Please review this log entry to discover what caused this error to occur. Error in Event Viewer: aspnet_wp.exe could not be started. The error code for the failure is 80004005. This error can be caused when the worker process account has insufficient rights to read the .NET Framework files. Please ensure that the .NET Framework is correctly installed and that the ACLs on the installation directory allow access to the configured account. OR aspnet_wp.exe could not be launched because the username and/or password supplied in the processModel section of the config file are invalid. Solution: Check out this microsoft support article >> http://suppor

[Non Tech] Want to know the recipe for Omelette :)

Fed up with Bread - Jam and Curd Rice, today i wanted to eat Omelette. Interesting part is I wanted to cook it myself :) So in the first picture you see all the items which are needed for preparing an Omelette. When I had a closer look at the eggs I see that almost all the eggs are broken. But believe me when I bought it couple of days back it was in perfect condition! I was wondering whether the eggs have become rotten or pretty old to consume! I tried taking an egg and break it but couldn't break it at all :) Since I have kept in the freezer all the eggs have frozen and looked like a iron ball :) After trying for few minutes of trying i removed the shell of the egg and then kept that iron ball :) into a bowl and placed it within Oven. I heated it for 1 minute and checked. It melted only to a limit. So i just set it for another 2 minutes and checked it later. It has melted but the part of the egg white has become a Omelette :( I didn't leave it there. I took the bowl out of

Max limit of Varchar, nvarchar, varbinary datatypes ...

As you would be knowing by now in SQL Server 2005 they have enhanced varchar, nvarchar & varbinary as varchar(max), nvarchar(max) & varbinary(max). So now they can hold upto 2^31-1 bytes (it would come to approx 2 GB). That said, don't think that just because MAX has been introduced you can declare those datatypes for any arbitary number. If you want to specify a limit yourself for those datatype still the maximum is 8000 characters. When you think that you need to store content whose lenght would be more than 8000 characters then you need to declare it as MAX. For example, Try executing the below code snippet Create table testVarchar ( fName varchar(8001) ) Go It would throw an error something like this: The size (8001) given to the column 'fName' exceeds the maximum allowed for any data type (8000).