Monday, August 21, 2017

Drag and Drop on Visual Studio

 Hi in this post I am going to "How we can easily create drag and drop code snippets in Visual Studio".Lets create a New Windows Form Application.  and Goto Cs File of form by pressing F7.





Select the code the you want to reuse on different form. For this example select try and catch block
and drag it to the toolbox on the left pane.


Once you drag and drop the Code you will sell the snippet in the toolbox.



You can rename code snippet by Right Clicking on the Code snippet and selection Rename Item.You can also group the code snippet by creating new Item.



That's all If you want to use the same code snippet in some other in the project you can simply drag and drop the code. I hope this post will be useful to you and helps to accelerate your code development .


No comments:

Post a Comment