error message with servo

Hello,
Very new to this and I dont know why I am getting this error message when i try to burn sketch to board: Arduino: 1.6.10 (Windows 7), Board: "Arduino/Genuino Uno"

Sketch uses 2,106 bytes (6%) of program storage space. Maximum is 32,256 bytes.
Global variables use 54 bytes (2%) of dynamic memory, leaving 1,994 bytes for local variables. Maximum is 2,048 bytes.
An error occurred while uploading the sketch

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

Here is my program:

#include <Servo.h>
Servo myservo;
void setup(){
myservo.attach(9);
myservo.write(0);
delay (1000);
}
void loop(){
myservo.write(30);
delay (1000);
myservo.write(150);
delay (1000);
}

I just want my servo to oscillate back and forth

Thank you!

Nothing wrong with the code.
Problem is with IDE settings or PC settings/drivers or how you have things plugged in.

Hmm thats weird, I just went thru a few tutorials burning the code to board a a few times and had no issues. However, I did restart the pc before receiving this error but I dont know what that wouldve done.

Which ports are offered when you do Tools/Port in the IDE ?

At the bottom of the screen it says Arduino Uno on COM1
Under tools>>Port: COM1(Arduino/Genuino/Uno) there are only 2 options serial port (which is grayed out) and COM1 which is selected.

If I remember correct 1.6.10 has a bug that sometimes prevent uploading sketch.
Try latest IDE 1.6.11.

That fixed it! Thank you!