h1.post-title { color:orange; font-family:verdana,Arial; font-weight:bold; padding-bottom:5px; text-shadow:#64665b 0px 1px 1px; font-size:32px; } -->

Pages

extern -- C# Keyword

extern -- C# Keyword

  •  The extern modifier is used to declare a method that is implemented externally.
  • A common use of the extern modifier is with the DllImport attribute when you are using Interop services to call into unmanaged code.
  • In this case, the method must also be declared as static, 

[DllImport("<dll Name>.dll")]
private static extern void <dll Method Name>();