Sunday, April 22, 2007

Code Snippets

Code Snippets

In addition to the 500 prewritten pieces of code included in-the-box, the Intellisense code snippet library is also extensible. This allows you to create new code snippets that suit your business needs, edit the ones that already exist, or download from third-party vendors and community sites. The code snippet editor is a tool you can use to help create your own snippets. Download the code snippet editor for Visual Basic 2005.

Visual Basic Code Snippets
Visual Basic ships with hundreds of code snippets in the following categories. We will be adding additional code snippets at this site in these categories and more in the coming months.

Application Code Snippets: For working with Isolated Storage, ClickOnce tasks, Console Applications and Process Management.
Collections Code Snippets: For tasks like creating, iterating, locating elements, and sorting collections like arrays and dictionaries.
Crystal Reports Code Snippets: For common reporting tasks such as printing a Crystal Report, setting report parameters, and configuring report data access.
Database Code Snippets: For performing a variety of common tasks around ADO.NET data access.
Data Types Code Snippets: For various string conversions, date spanning operations, and other type-focused operations.
File System Code Snippets: For performing a number of tasks around reading, writing, and managing files.
Language Code Snippets: For inserting conditionals, looping, exception handling, properties, procedures, types and more.
Network Connectivity Code Snippets: For checking network status, downloading a file via HTTP, performing serial port operations, sending email and more.
Operating System Code Snippets: A large collection of snippets for Event logging, Message Queues, Process management, registry access, windows services, getting system information and more.
Security Code Snippets: For working with hashes, decrypting, encrypting, and getting a user’s name.
Smart Devices Code Snippets: For performing common tasks on Smart Devices.
Windows Forms Code Snippets: For working with the clipboard, fonts, sounds, GDI drawing, and general Windows Form and control creation.
XML Code Snippets: For reading and writing XML, selecting nodes, performing XSL transforms, and other XML oriented tasks.