Error message during compilation

Hi, I am trying to use the example given on how to use the Arduino Shield WiFi 101 to to scan for available networks but each time I try to verify the code, an error message appears. Attached is the snapshot of the Arduino IDE showing the error message.

Please post the program that causes the problem and the text (copy/paste) of the error message(s) not a picture of them. Read and follow the advice in read this before posting a programming question

Below is the code:

#include <SPI.h>
#include <WiFi101.h>

void setup() {
// initialize serial and wait for the port to open:
Serial.begin(9600);
while(!Serial) ;

// attempt to connect using WEP encryption:
Serial.println(“Initializing Wifi…”);
printMacAddress();

// scan for existing networks:
Serial.println(“Scanning available networks…”);
listNetworks();
}

void loop() {
delay(10000);
// scan for existing networks:
Serial.println(“Scanning available networks…”);
listNetworks();
}

void printMacAddress() {
// the MAC address of your Wifi shield
byte mac[6];

// print your MAC address:
WiFi.macAddress(mac);
Serial.print(“MAC: “);
Serial.print(mac[5],HEX);
Serial.print(”:”);
Serial.print(mac[4],HEX);
Serial.print(":");
Serial.print(mac[3],HEX);
Serial.print(":");
Serial.print(mac[2],HEX);
Serial.print(":");
Serial.print(mac[1],HEX);
Serial.print(":");
Serial.println(mac[0],HEX);
}

void listNetworks() {
// scan for nearby networks:
Serial.println("** Scan Networks **");
byte numSsid = WiFi.scanNetworks();

// print the list of networks seen:
Serial.print(“number of available networks:”);
Serial.println(numSsid);

// print the network number and name for each network found:
for (int thisNet = 0; thisNet<numSsid; thisNet++) {
Serial.print(thisNet);
Serial.print(") “);
Serial.print(WiFi.SSID(thisNet));
Serial.print(”\tSignal: “);
Serial.print(WiFi.RSSI(thisNet));
Serial.print(” dBm");
Serial.print("\tEncryption: ");
Serial.println(WiFi.encryptionType(thisNet));
}
}

Below is the error message:

Arduino: 1.6.8 (Windows 7), Board: “Arduino/Genuino Mega or Mega 2560, ATmega2560 (Mega 2560)”

C:\Users\Ogu\Documents\Arduino\sketch_apr29a\sketch_apr29a.ino:2:21: fatal error: WiFi101.h: No such file or directory

#include <WiFi101.h>

^

compilation terminated.

exit status 1
Error compiling for board Arduino/Genuino Mega or Mega 2560.

This report would have more information with
“Show verbose output during compilation”
option enabled in File → Preferences.

If you did read the advice in the link that I posted you didn't take note about using [­code] [­/code] tags

Do you actually have a file named WiFi101.h on your PC and if so where is it located ?

Thank you very much. I later downloaded the WiFi101 library and installed it. The sketch is now OK.

Did you actually read the error message ? It was telling you exactly what the problem was.