Infrared receiver not working

I am trying to set up an infrared receiver to display the value it revives, but it is printing nothing to the serial monitor. The remote I am using works and the receivers led showing its on is working well also.

#include "IRremote.h"
const int receiver = 3;
IRrecv irrecv(receiver);
decode_results results;
void setup() {
  // put your setup code here, to run once:
  Serial.begin(9600);
  irrecv.enableIRIn();
  Serial.print("starting...");
}

void loop() {
  // put your main code here, to run repeatedly:
  if (irrecv.decode(&results)){
    irrecv.resume();
    delay(200);
    Serial.println(results.value, HEX);
    
    Serial.print("works?");
  }
}

In advance thank you for the help.

Hello monkey02psycho,

does serial monitor prints

starting...

If "YES" there should be problem with the connection or with the code, if "NO" check for the baudrate setting on Serial monitor if it's matches with the code which is 9600.

why don't you try with IRTest and IRTest2 examples.?

Thank you

mudassir9999:
Hello monkey02psycho,

does serial monitor prints If "YES" there should be problem with the connection or with the code, if "NO" check for the baudrate setting on Serial monitor if it's matches with the code which is 9600.

why don't you try with IRTest and IRTest2 examples.?

Thank you

the serial monitor does print starting... i have tried uploading the codes for the IRtest and IRtest2, but now as soon as i wire in the receiver my computer does not recognize the bored(i have the weirdest computer problems)