Find the value of cos(theta) if sin(theta)=8/17 and cos(theta)<0.

I cannot seem to get the right answer but here is what I did.

Cos= adjacent/ hypoteneuse

Sin= Opposite/ hypoteneuse

Now I drew a right trible and labeled the angle with respect to theta. So the hypotenese was 17 and the base was 15. Now to find the right side of the triangle I applied Pathyogreans theorm (I can't spell) and set it up like this:

8^2+B^2=17^2 ; solved for b and 15.

According to me Cosine, which I am looking for should be (15/17) but somehow when I am typing the information back into the comuter system it wont accept the answer, what am I doing wrong?

Thanks