Rotary encoder + 7 segment display.

I'm making passive volume control and I have about 60-64 steps.

In void loop for test I have write this:

if (encoder[i].count = 1)
{
digitalWrite(Relay1, HIGH)
}

And I get this: 'i' was not declared in this scope