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 CS0121

The call is ambiguous between 'function1' and 'function2'

Due to implicit conversion, the compiler was not able to call one form of an overloaded method. You can resolve this error either by specifying the method parameters in such a way that implicit conversion does not take place. Or, you could remove all overloads for the method.

The following sample generates CS0121:

public class C {
   void f(int i, double d) {
}
   void f(double d, int i) {
}
   public static void Main() {
      C c = new C();

      c.f(1, 1);   // CS0121
      // try the following line instead
      // c.f(1, 1.0);
      // or
      // c.f(1.0, 1);
   }
}