Controlling Arduino from C#: trouble reading int with serialread & loop

Hi everyone,
i’m having a little trouble with a project of mine which is a solar tracker with LDR’s. I wrote a little application in VS C# which sends numbers (see attached picture) to the Arduino. The idea behind the application is it starts of with Auto mode so the arduino reads the ldr values and moves some stepper motors. Once i click Manual in my c# application a “2” is sent to the arduino and should go into another loop where i can move the stepper motors in the desired position by sending “3” for up, “4” for left, etc. Also i want to be able to go back into Auto mode by sending a “1”.

I’ve been trying to write the correct loops for a while now and its doing my head in, maybe its also too late at night.
Here is the arduino code how i thought it should look like but its not working.

int state_mode = 0;
int readval = 0;
int manualdir = 0;

void setup()
{
  Serial.begin(9600);
  ...
}

void loop()
{
  readval = Serial.Read();
  if(readval == 1 || readval == 2)
  {
    statemode = readval;
  }
  //AUTO MODE//
  if(state_mode == 1)
    {
      int right = analogRead(ldr1);  // read right ldr value
      .
      .
      boolean moveleft = (left - right) > 20 && angLR >= minH && angLR < (maxH + 0.01) && left > 970;
      .
      .
      //HORIZONTAL MOVEMENT//
      if(moveleft) 
      {
        stepperh->onestep(FORWARD,DOUBLE); 
        angLR -= stepsize;  // subtract one stepsize from horizontal angle
      }
      else if(moveright)
      .
      .
    }
      //MANUALL MODE//
      if (state_mode == 2)
      {
        manualdir = Serial.Read();
            if (manualdir == 3)  //up clicked in c# app
            {    
              // move left
            }
            if (manualdir == 4)  //left clicked in c# app  
            {
              // move up
            }
              .
              .
          }
      }
}

I would appreciate any ideas or approaches to make this work.

Untitled.jpg

readval = Serial.Read();

"read" should be lower-case

void setup()
{
  Serial.begin(9600);
  ...

I don't think the compiler likes ellipsis

Here is the arduino code how i thought it should look like but its not working.

For what definition of work? The code won't even compile.

Post code that DOES compile, unless that is your problem. If it is, then post the error messages.