I have found an error in a textbook. What can I do about it?
First of all, see if the book has a newer edition, and try to look at a copy and see if it corrects the error.  

If not, then try to find:


The publisher's web page for the book
The author's professional web page, which hopefully has some mention of the book.
An unofficial errata list (google the book's title and "errata" or "corrections").


Check in both places for an errata list, which may already have a correction of the error.

If not, then it is worth trying to report it.  Writing the email is the easy part: just politely point out that you believe there is an error on page NNN, and explain as completely as possible why you believe it is incorrect.  If you think you know how it could be corrected, you could explain that as well, but it isn't strictly necessary.

The hard part is figuring out where to send it; publishers and authors should make this obvious, but often they do not.  

For a major established textbook (which I assume this is), I would focus on the publisher, since the original author may well not be actively involved with the book anymore.  See if there is any contact or feedback information on the book's web page.

If you are a faculty member, the publisher probably has assigned a representative for your institution.  You may get a better response by contacting your rep directly and asking them to forward your report to the appropriate person.  If you are a student and this is your course text, you could ask your professor to contact the publisher's rep.

If there is an unofficial errata list, it should include contact information for the person who's maintaining it; send a report to them.

For a text or monograph with a smaller audience, you will probably do better to contact the author directly; look for contact info on their professional web page.

It's a good service to the community to report errors in books so they can eventually be fixed, so thanks for doing this.  However, if the publisher/author make it a huge pain to do so, that is ultimately their problem.  Make a reasonable effort to report it to an appropriate person, but if you don't succeed, there's no need for heroic efforts.