Microsoft Visual Studio provides powerful features helping in rapid code development and make developer productive. In this article introducing one such feature that reduce expensive copy-paste operations when there is a same piece code snippet to be reused in multiple code blocks. Yes, it’s about how to store and use reusable code from Visual Studio tool box.
For example: Suppose if you need to add trace log related code in each code block then most of the time you copy the existing line of a code which was already written in some code file. Copy and past operation is little bit expensive when there is a common code to be written across the project.
Store and use reusable code from Visual Studio tool box:
In Visual Studio, you can keep this peace of code in the tool box and you can reuse this code when required. You just need to drag and drop the code line from the tool box to your code editor pane. This is similar to drag drop Button control to form.
Follow the below steps to see how to move code snippet into tool box in Visual Studio.
– Article ends here –
Software engineer by profession, founder of troubleshottyourself channel and enthusiastic blogger. Love to write articles on new technology, programming,