Help for Ultrasonic Module HC-SR04 controlling Relay

Hello, I have a little Problem with my sketch the Relay didn´t go on.

Does anybody have an answer for this problem?

Here is my sketch:

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

long duration, distance;

#define trigPin 13
#define echoPin 12
#define led 11
#define led2 10

#define RELAY_ON 0
#define RELAY_OFF 1

#define Relay_1 38

void setup() {
Serial.begin (9600);
pinMode(trigPin, OUTPUT);
pinMode(echoPin, INPUT);
pinMode(led, OUTPUT);
pinMode(led2, OUTPUT);

digitalWrite(Relay_1, RELAY_OFF); // Relay 16

pinMode(Relay_1, OUTPUT); // Relay 16

}

void loop() {

long duration, distance;
digitalWrite(trigPin, LOW); // Added this line
delayMicroseconds(2); // Added this line
digitalWrite(trigPin, HIGH);
// delayMicroseconds(1000); - Removed this line
delayMicroseconds(10); // Added this line
digitalWrite(trigPin, LOW);
duration = pulseIn(echoPin, HIGH);
distance = (duration/2) / 29.1;
if (distance < 4) { // This is where the LED On/Off happens
digitalWrite(led,HIGH); // When the Red condition is met, the Green LED should turn off
digitalWrite(led2,LOW);
}
else {
digitalWrite(led,LOW);
digitalWrite(led2,HIGH);
}
if (distance >= 200 || distance <= 0){
Serial.println(“Out of range”);
}
else {
Serial.print(distance);
Serial.println(" cm");
}
delay(500);
}
void Relais1() {

if ( distance <=20 )
{
digitalWrite(Relay_1, RELAY_ON);
}
else
{
digitalWrite(Relay_1, RELAY_OFF);

}
}

When you add some serial prints to debug your problem, are you getting measurement data from the sensor?
Looks like you have both global and local variables for:
duration, distance;

Edit:
void Relais1() { // <<<< this will access the global variable but your calculation is done on the local variable.

Ok it work thank you very much for your help.

best regards