C# error CS0201: Only assignment, call, increment, decrement, and new object expressions can be used as a statement

前端 未结 2 1056
無奈伤痛
無奈伤痛 2021-01-28 05:40

Here is the line where I am getting error:

_activeType == typeof(Reticle);

Here is how the Reticle class is defined. Some of the p

相关标签:
2条回答
  • 2021-01-28 05:57

    _activeType = typeof(Reticle);

    == is a comparison operator ( for comparing )

    0 讨论(0)
  • 2021-01-28 06:15

    I think you meant

    _activeType = typeof(Reticle);
    

    not the double ==

    0 讨论(0)
提交回复
热议问题