expected unqualified-id before '.' token

Hi, not sure how to fix this pls help! Error in the line Servo.Write(position_last_set);

#include <Servo.h>
#define SERVO_PIN 9
#define GROUND_JOY_PIN A3 //joystick ground pin will connect to Arduino analog pin A3
#define VOUT_JOY_PIN A2 //joystick +5 V pin will connect to Arduino analog pin A2
#define XJOY_PIN A1 //X axis reading from joystick will go into analog pin A1
Servo myservo ;
#define position_target
int position_target ;

int position_last_set ;
void setup()
{
Serial.begin(9600);
pinMode(VOUT_JOY_PIN, OUTPUT) ; //pin A3 shall be used as output
pinMode(GROUND_JOY_PIN, OUTPUT) ; //pin A2 shall be used as output
digitalWrite(VOUT_JOY_PIN, HIGH) ; //set pin A3 to high (+5V)
digitalWrite(GROUND_JOY_PIN,LOW) ; //set pin A3 to low (ground)
myservo.attach(9);
}

void loop()
{
delay(200);
int joystickXVal = analogRead(XJOY_PIN) ; //read joystick input on pin A1
Serial.print(joystickXVal); //print the value from A1
Serial.println(" = input from joystick"); //print "=input from joystick" next to the value
Serial.print((joystickXVal+520)/10); //print a from A1 calculated, scaled value
Serial.println(" = output to servo"); //print "=output to servo" next to the value
Serial.println() ;
myservo.write((joystickXVal+520)/10); //write the calculated value to the servo

if(position_target) != position_last_set)
{
Servo.Write(position_last_set);
position_last_set = position_target;
}
}

What is "Servo.Write?

Where is it defined?

Your problem starts here.

  if(position_target) != position_last_set)

Please remember to use code tags when posting code

@AWOL Basically I'm wanting the servo to 'stop' when it reaches a position the user wants it to be in. I didn't know how to stop it so I searched it online and the 'if' section was said to be the solution, so I just copied and pasted it. (By the way I'm very new to coding)

Also I defined Servo.write, and the line you picked out came up with the error expected primary-expression before '!=' token

Servo.Write is not the same as Servo.write .

What do you mean by "... I defined Servo.write..." ?

Why do you think you can have an extra right parenthesis?

Why did you not use auto-format before posting?

...and Servo.write is not the same as myservo.write.

I know the line I picked out was before the error the compiler indicated.

That's because the line I pointed-out contains the error, but the compiler only found the fault when it tried to make sense of the next hatstand.