NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Compiler Error CS0012

Cannot find a definition for referenced type 'type'

The definition for a referenced type was not found. This could occur if a required .DLL file is not included in the compilation. For example, the following sequence of compilations will result in a CS0012 error:

// B1.CS
class B1 {
   public static void Main() {
   }
}

Then:

// B2.CS; compile with /r:b1.exe
class B2: B1 {
   public static void Main() {     
   }
}

Ignoring the CS0114 warning. Then:

// D.CS; compile with /r:b2.exe
class D: B2 {   // CS0012
   public static void Main() {
   }
}

You could resolve this CS0012 by compiling with /r:b2.exe;b1.exe.