Facebook Twitter


Development Tools and Languages. Code Snippets. A code snippet is a block of reusable code that you can insert where you need it in your code.

Code Snippets

Snippets can be simple or more complex—for example, blocks such as try-finally and if-else are commonly used, but you could also use snippets to insert entire classes or methods. Visual Studio enables two kinds of code snippet: insertion snippets, which are added at a specified insertion point, and surround-with snippets (C# and C++ only), which are added around a selected block of code. To insert an insertion snippet in your code, put the cursor where you want the snippet to appear, open the shortcut menu, choose Insert Snippet, and then navigate to the snippet you want, select it, and press the Tab key.

If you already know the name of the snippet, just type its name at the cursor and then press Tab+Tab. Grasshopper – The Visual Studio Plugin for .NET Java applications. Mainsoft.com Search What is Grasshopper? Key features MSIL to Java bytecode compilation Java EE compliant applications Visual Studio integration Access to external Java components Open source .NET Framework Powered by Grasshopper <div style="display:none"> <a href=" <a href=" <a href=" <a href=" <a href=" <a href=" </div> Mainsoft ® for Java EE (aka Grasshopper), a freely available Visual Studio plug-in that you can use to create server and ASP.NET applications, or port existing .NET applications to Linux and other Java-enabled platforms, without having to re-write your code in the Java language. .NET to Java: MSIL to Java bytecode compilation Grasshopper provides a patented cross-compiler that compiles Microsoft Intermediate Language (MSIL) into standard Java bytecode.

Grasshopper produces pure Java deployment packages that can be deployed on any Java EE compliant application server, on any platform, using regular Java EE deployment tools. Enhanced Visual Studio editing capabilities Help system. Failure trying to start user instance. Pre-defined Keyboard Shortcuts. You can more easily access a variety of commands and windows in Visual Studio by choosing the appropriate keyboard shortcut.

Pre-defined Keyboard Shortcuts

This topics lists the default shortcuts for the General Development profile, which you might have chosen when you installed Visual Studio. No matter which profile you chose, you can identify the shortcut for a command by opening the Options dialog box, expanding the Environment node, and then choosing Keyboard. You can also customize your shortcuts by assigning a different shortcut to any given command.

Data access

Visual C# C# (pronounced "C sharp") is a programming language that is designed for building a variety of applications that run on the .NET Framework.

Visual C#

C# is simple, powerful, type-safe, and object-oriented. The many innovations in C# enable rapid application development while retaining the expressiveness and elegance of C-style languages. Visual C# is an implementation of the C# language by Microsoft. Visual Studio supports Visual C# with a full-featured code editor, compiler, project templates, designers, code wizards, a powerful and easy-to-use debugger, and other tools. The .NET Framework class library provides access to many operating system services and other useful, well-designed classes that speed up the development cycle significantly. Extension Methods (C# Programming Guide) Extension methods enable you to "add" methods to existing types without creating a new derived type, recompiling, or otherwise modifying the original type.

Extension Methods (C# Programming Guide)

Extension methods are a special kind of static method, but they are called as if they were instance methods on the extended type. For client code written in C# and Visual Basic, there is no apparent difference between calling an extension method and the methods that are actually defined in a type. The most common extension methods are the LINQ standard query operators that add query functionality to the existing System.Collections.IEnumerable and System.Collections.Generic.IEnumerable<T> types. To use the standard query operators, first bring them into scope with a using System.Linq directive.

Then any type that implements IEnumerable<T> appears to have instance methods such as GroupBy, OrderBy, Average, and so on. The following example shows how to call the standard query operator OrderBy method on an array of integers. Access Modifiers (C# Reference) Access modifiers are keywords used to specify the declared accessibility of a member or a type.

Access Modifiers (C# Reference)

This section introduces the four access modifiers: The following five accessibility levels can be specified using the access modifiers: XML Documentation Comments (C# Programming Guide) In Visual C# you can create documentation for your code by including XML elements in special comment fields (indicated by triple slashes) in the source code directly before the code block to which the comments refer, for example: /// <summary> /// This class performs an important function. /// </summary> public class MyClass{} When you compile with the /doc option, the compiler will search for all XML tags in the source code and create an XML documentation file.

XML Documentation Comments (C# Programming Guide)

To create the final documentation based on the compiler-generated file, you can create a custom tool or use a tool such as Sandcastle. Design Guidelines for Developing Class Libraries. This section provides guidelines for designing libraries that extend and interact with the .NET Framework.

Design Guidelines for Developing Class Libraries

The goal is to help library designers ensure API consistency and ease of use by providing a unified programming model that is independent of the programming language used for development. We recommend that you follow these design guidelines when developing classes and components that extend the .NET Framework. Inconsistent library design adversely affects developer productivity and discourages adoption.

The guidelines are organized as simple recommendations prefixed with the terms Do, Consider, Avoid, and Do not. These guidelines are intended to help class library designers understand the trade-offs between different solutions. These guidelines are excerpted from the book Framework Design Guidelines: Conventions, Idioms, and Patterns for Reusable .NET Libraries, 2nd Edition, by Krzysztof Cwalina and Brad Abrams.