Browse by Tags
All Tags »
VS 2005 (
RSS)
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" ...
Whenever possible, i rather to use UserControl instead of WebControl, since WebControls are more complicate to create and later on to maintain. But in case that i have to build a WebControl, i rather build a CompositeControl. Way CompositeControl? CompositeControl eventually inherit from WebControl, but each control inside the CompositeControl manage its own life cycle events and the ViewState / PostBack data. This means that we going to save a lots of code writing by not handling this events our...
I didn't find a way to delete projects from my Recent Projects List in visual studio 2005, so I made this Add-In to manage them. Place the 2 files in the RecentProjectsManager.zip (Attached) into the Add-In folder: MyDocuments\Visual Studio 2005\Addins Load the visual studio, click "Tools" and then "Recent Projects Manager" Please let me know about any problems you encountered: gilad.lavian@gmail.com
Here is a little IRC API that I wrote allows you to connect to IRC server easily. The syntax to create the IrcClient is: 1: //Set the server details 2: ServerInfo serverInfo = new ServerInfo( "irc.mircx.co.il" , 6667, "GiladBot" , "Gilad C# Bot" , "gilad.lavian@gmail.com" , "#test" ); 3: 4: //Create a IrcClient 5: IrcClient ircClient = IrcClientFactory.CreateIrcClient(serverInfo); 6: 7: //Subscribe to the irc server events 8: ircClient.OnServerText...
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"...
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...
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><...