I'm trying to finish my last parts of the code, and I need to check the value of string
, but I can not find any examples of how to handle it. I tried this code but the error appears:
Error 1 Can not implicitly convert type 'string' to 'bool'
TestForm.cs 956 17
This is my variable:
public string malcoins = "0";
And here's the code:
if (malcoins = "100000")
{
}
I need to compare if the variable is = 100000
, otherwise I disable button2