set cursor was not declared in this scope

so i tried this code

#include <LiquidCrystal.h>

// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);
int i=15;
void setup() {
// set up the LCD’s number of columns and rows:
lcd.begin(16,2);

}

void loop() {
lcd.setCursor(16,0);
lcd.autoscroll();
lcd.print(“o”);
delay(1000);
i–;
if (i=0) setCursor(16,0);
}

but i get " set cursor was not declared in this scope"
please help :confused:

  if (i==0) lcd.setCursor(16,0);

The compile error may be related to which LiquidCrystal library you are using. Try using a different one.

raschemmel: The compile error may be related to which LiquidCrystal library you are using. Try using a different one.

Doesn't look like it - the first use of setCursor correctly uses an lcd object. The second doesn't.

Oh right.. In addition to omitting the "lcd." in front of "setCursor", it also used an assign operative ("=")instead of a conditional. ("==")

raschemmel: Oh right.. In addition to omitting the "lcd." in front of "setCursor", it also used an assign operative ("=")instead of a conditional. ("==")

Psst, see reply #1

Psst, see reply #1

Yes, I saw that , thank you, but the first time I looked at it I only noticed that the "lcd." was missing. I didn't notice the "=" until my last post. My post that you quoted was only Reply#4 so I was only 3 Replies behind... Give me a break....

thank you guys!! can't beleive i didn't notice that!! :p i apreciate your help.