Need preprocessor advice

I want to let the preprocessor do some work for me.
But it seems not to accept my contruction.

// lcd display control
#ifdef LCD_I2C
#else
const byte _backLightOn = 0x11; 	// lcd back light on
const byte _cursorOff = 0x16;	// lcd cursor off
const byte _clearScreen = 0x0C;	// lcd clear screen
const byte _line0 = 0x80;	// lcd line 0 - top line
const byte _line1 = 0x94;	// lcd line 1 - bottom or 2nd line
#ifdef LCD_SER_4X20
const byte _line2 = 0xA8;	// lcd line 2 - 3th line
const byte _line3 = 0xBC;	// lcd line 3 - bottom line
String _clearString = "                    ";
#else
String _clearString = "                ";
#endif 
#endif

It should not do any thing if the LCD_I2C def is true.
But if not then the else part.
And in this if part contains a other ifdef and the preprocessr is not accepting this

Use the '#ifndef' preprocessor directive instead; it makes your (nested) conditions less convoluted.

kind regards,

Jos

couls you please explain that. Where should i use the #ifndef?
I am not a expert that has enough on one sentence, sorry

The ifndef is like putting an ! before something in an if statement - it reverses it. So, with your code, you want to create the constants if LCD_I2C is not defined. Rather than having an empty ifdef, you can do this:

// lcd display control
#ifndef LCD_I2C
const byte _backLightOn = 0x11; 	// lcd back light on
const byte _cursorOff = 0x16;	// lcd cursor off
const byte _clearScreen = 0x0C;	// lcd clear screen
const byte _line0 = 0x80;	// lcd line 0 - top line
const byte _line1 = 0x94;	// lcd line 1 - bottom or 2nd line
// rest of code hidden