"if" was not declaired in this scope problem


Hi Arduino Friends
I have a coding issue, that I just cannot fathom out, so would appreciate any help from the many Arduino experts here.

The code in the image will not compile because of the last "if" statement - the error is "if was not declaired in this scope"?

Many thanks to anyone that can give me their sage advice!

If should be if (lower case).

1 Like

Thanks jfjlaros - how did I miss that! - I really appreciate your prompt help!

This is not the error is it? Also I guess we see you again when compiler throws ‘count’ is undefined error?

Good to hear that your issue has been resolved.

Can you please mark the most helpful post as the solution? This prevents helpers spending time on a solved issue and it will lead people with the same question to the correct answer directly.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.