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 C2680

'type' : invalid target type for name

A casting operator tried to convert to a type that is not a pointer or reference. The dynamic_cast operator can be used only for pointers or references.

Example

class A { virtual void f(); };
class B : public A {};

void g(B b)
{
    A a;
    a = dynamic_cast<A>(b);  // error
}