Can't attach servo, what am i doing wrong?

#include <Servo.h>
Servo myservo;
void setup()
{
Serial.begin(9600);
Serial.print("Setup");
myservo.attach(7);
}
void loop() {
if (myservo.attached()){
Serial.print("No\n");
myservo.detach();
myservo.attach(7);
}else{
Serial.print("Yes\n");
}
delay(2000);
}

It's connected but it wont attache, this code keeps printing No

hm :

if(myservo.attached) would be true if it's attached so it goes to this if and there you say "no", and would go to else and say yes if it was not atached :S

servo.attach(7);//servo is attached
if(servo.attached()){ //will enter this if because servo is atached
println("yes");//print yes because yes, servo is atached
}else{
println("no");//print no because servo is not atached
}

try to move it instead of doing this atach joke

Wow..I'm sorry, I'm an idiot. That should be an ! in there so I guess it was working. :-X :-[

lol, this is solved