Keyboard.h or Mouse.h not found.

So I have an arduino micro, and all documentation online tells me that it should automatically have the libraries installed, which it does.
But for some reason when I try to compile and validate the testprogram it tells me 'Mouse' or 'Keyboard' for that matter, is not found.
I have the line '#include <Mouse.h>' in the code, and it still doesn't work.
I found this question on this forum from a long time ago but it seemed to have died before the answer came.
Maybe any of you guys know how to fix this?

#include<Mouse.h>            


const int input = 3;


void setup()             
{   
  pinMode(input , INPUT);    

  Mouse.begin();         
}

void loop()            
{
  if (digitalRead(input) == LOW)      
  {
    Mouse.click();
  }
}

Thanks in advance!

Did you forget to select Tools->Board->Arduino/Genuino Micro?

Oh yes I have, thanks for the quick reply! :slight_smile: