Permalink
Fetching contributors…
Cannot retrieve contributors at this time
50 lines (45 sloc) 1.58 KB
title ms.date ms.prod ms.technology ms.topic f1_keywords dev_langs helpviewer_keywords ms.assetid caps.latest.revision author ms.author translation.priority.ht
using (C# Reference)
2015-07-20
.net
devlang-csharp
article
using_CSharpKeyword
using
CSharp
using keyword [C#]
124e1a63-2a4b-4132-b269-3b6d8d3ef72d
11
BillWagner
wiwagn
cs-cz
de-de
es-es
fr-fr
it-it
ja-jp
ko-kr
pl-pl
pt-br
ru-ru
tr-tr
zh-cn
zh-tw

using (C# Reference)

The using keyword has two major uses:

  • As a directive, when it is used to create an alias for a namespace or to import types defined in other namespaces. See using Directive.

  • As a statement, when it defines a scope at the end of which an object will be disposed. See using Statement.

In addition, the using static directive lets you define a type whose static members you can access without specifying a type name.

See Also

C# Reference
C# Programming Guide
C# Keywords
Namespace Keywords
Namespaces
extern