Top Snippets
This snippet shows how to develop a custom panel which is semi transparent by overriding CreateParams and the OnPaint method of the Panel control.
TThis code snippet gets the filename and path of a selected file using the FileOpenDialog Class.
This snippet adds items to a listview control. It loops through the files in the C:\ drive and displays the filename in the listview control.
This sinppet opens an image for reading as bytes. The bytes are then placed into a memorystream which is used to create a bitmap image of the bytes. The image is then set as the forms background image.
This snippet uses the TripleDESCryptoServiceProvider Class to encrypt a string and save it to a text file. The key to decrypt the file is also saved into a seperate text file.
This code snippet gets the filename of a selected file from the Open File Dialog and displays it in a message box.
This snippet checks to see if a file exists using the FileInfo Class.
This code snippet will get the computers IP address.
This simple snippet creates a connection to an SQLServer.
This code snippet shows how to use the PrintDocument class to print documents. It uses the PrintPreviewDialog to show the preview of the document a button to print the docuemnt.