DCSIMG
VS 2005,Code Better - Gilad Lavian's Blog

Gilad Lavian's Blog

In Development

Browse by Tags

All Tags » VS 2005 » Code Better (RSS)
Code Snippet RW (Response.Write)
Code Snippet For Response.Write   Ok, this code snippet must be the oldest trick in the book, but still I think it will help to developers how doesn't know about it.   1. Create a file name rw.snippet 2. Copy this XML code and save it. 3. From the tools menu in VS, select "Code Snippets manager". 4. Select import, and point it to the saved file. 5. To use the snippet write rw in the code editor. 6. Enjoy!   <?xml version="1.0" encoding="utf-8" ...
Cool trick with TAB in Visual Studio for auto completing code blocks
I found a cool trick for auto completing some code blocks. Personally, I find it very convenient while i'm in hyperspace speed coding. Its called snippets and its built-in in Visual Studio, and you can create one yoursefe. When you start a new "try" block, after finishing to write "try", immediately press TAB button, it will auto complete to: try { } catch ( Exception ) { throw ; } When you start a new condition block, "if (2 > 1)", and after you add the "else"...
Visual Studio shortcuts keys
You 2 can become a visual studio shotrcut keys GURU ! http://www.dofactory.com/ShortCutKeys/ShortCutKeys.aspx Mister Miagi once said: Rule number one, breathe in and... breathe out ! Rule number two, first learn rule number one...
Transform an XML to HTML - StringReader
Here is a great way to transform an XML string returned from DB Query to a HTML using DataGrid/List... The xml represent by the StringReader, witch implements a TextReader that reads from a string. Then loaded to DataSet (by ds.ReadXML), and finally binds to the DataGrid. //Supposed this is the text returning from DB... string xml = "<rows><row id='1'><name>Gilad</name><address>Burla</address>" + "<country>Israel</country><...