Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Error CS0201 | Need Help

edited July 2022 in Programming

The following lines of code are having this error: [error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement]

Does anyone know why?

if (!foundRes)


ResItem newRes = new ResItem();

newRes.horizontal == Screen.width;

newRes.vertical == Screen.height;


selectedResolution = resolutions.Count - 1;



Sign In or Register to comment.