If you are using Visual Studio 2005 or 2008, for every asp.net or Html control, you need to explicity write runat=”server” attribute. Sometimes I really wonder, why I have to write this attribute for every control as most of time I want to access controls on server side. Is n’t is tedious task? It should be added automatically. But it’s not possible with Visual Studio 2005 or 2008.
Well, we have a good news now. Now there is no need to type runat=”server“. It does not mean that It has been removed. Nope.. it’s get added automatically in VS 2010. Wow.. amazing..
In VS 2010, Microsoft has added hundereds of new code snippest for HTML, JavaScript and for ASPX. If you want to place a textbox on the page, type tb and press Tab. Wow… You will see something like this..
<asp:TextBox ID="TextBox1" runat="server"/>
Type req and press Tab. Boom…
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="TextBox1" ErrorMessage="errormessage"></asp:RequiredFieldValidator>
There are lots of other code snippest almost for every control. Even for HTML tag also like table. Is n’t is cool?
No comments:
Post a Comment