Follow

What is CS0428?

Symptoms

When trying to enter play mode, I am receiving the error below:

error CS0428: Cannot convert method group `__' to non-delegate type `__' 
Consider using parentheses to invoke the method

Cause

The CS0428 error is caused when converting a method group to a non-delegate type, or attempting to invoke a method without using parentheses.

Error displayed in this example:

error CS0428: Cannot convert method group `GetComponent' to non-delegate 
type `EnemyScript'. Consider using parentheses to invoke the method

Resolution

To fix the CS0428 error you will need to add the parentheses where they are expected.

More Information

https://msdn.microsoft.com/en-us/library/02dw211c(v=vs.90).aspx

 

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.