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.

How to Avoid Accidentally Update of Record in Sql

I am writing this  post after i accidentally update all the records in a table. To avoid accidental  update just follow this simple method . Before executing the query just put a "Begin Transaction" above your query and "Rollback Transaction" after your Query.

Copy Paste Image Directly in Windows Form

 Hi in this tutorial we are going to see "how to set image in a clipboard directly as a Windows form Background". Lets Create a new Windows Form Project and add a following code in it.

Creating User Control in C#

 Hi in this tutorial I am going to show "How to Create Your own User Control"  and reuse it different windows form. So Lets Create a New Windows C# Project and name it as you like it.

Filter DataGridView using TextBox in C#

 Hi this post explains how to filter data in DataGridView using textbox as filter to search data in Gridview. For this tutorial I am using Northwnd database "Customer" Table .

Drag and Drop Text Files on Windows Form

This post explains how we can directly drag and drop text files in Windows Form. so whenever you drag and drop the text files it will be open in the Application. Let's Create a new new C# Windows Form Application project and name it as Drag and Drop.

Motion Detection using C# and Accord .Net

This blog shows how to perform Motion Detection using C# and Accord .Net.I assume you already installed accord .net in your system if not click here to know how to install and setup accord.net.Let's create a new new windows C# application project and add the following references to "Accord .Imaging.dll","Accord.Video.dll","Accord.Vision.dll","Accord.Video.Directshow.dll","Accord.dll".

Live Feed from WebCam using C#

This blog explains how to get live feed from web cam using c# and Accord Dot net framework.The Accord.Net Framework is a machine learning framework combined with audio and image processing libraries which is completely written in c#. To download accord.net framework follow this link.

Drag And Drop on Windows Form in C#

This post explains how we can directly drag and drop files on Windows Form.In this post i dynamically change the windows form background by using draganddrop event.Let' s create a new C# Windows Form Application and name it as Drag and Drop.

Create Startup Program using C#

 This post shows how to launch your application on system startup using few lines of codes in C#.Launching your application at windows start up is useful for checking updates etc.Create a new windows form application and design a form as shown below.

Hide Application using C#

Hi this post show how to to hide your C# Application in system tray.To hide your program in system tray you need "notifyicon" control from toolbox.Create a new windows application and design a form like this

Task Scheduler in C#

This post show how to create a simple task scheduler in C#.The program takes input(hours,minutes) from the user and display a message box at a specific time(Input Time).Create a new C# Windows Form Project in Visual studio.

Text to Speech in C#

This post explains how to create a text to speech application in c#. For this first you need to add "System.speech” references to your project.Create a new windows from application

Send Email from c#

This post shows how to send email from C# using various protocols available in the .Net framework.The System.Net and System.Net.Sockets are the two namespaces used for managed implementation of internet protocols that application can use to send and receive data over the internet.