Reputation: 1
private int Score;
public void Update ()
{
var t = ToString(Score);
if (ElementCompleted == true)
{
Score += 1;
ElementCompleted = false;
}
}
This gives me an error:
No overload for method
ToString
takes '1' arguments
Can anyone help me? I am not using ToString
anywhere else in my project.
Upvotes: 0
Views: 2311
Reputation: 19
it's telling you there is not a method toString() that takes 1 arguments because any toString method should always takes 0 arguments and you have sent it 1 argument score
Upvotes: 0
Reputation: 190925
Don't you mean to do Score.ToString()
?
Otherwise, you are doing this.ToString()
.
Upvotes: 6