I really wish authors' visions of reality were indeed true. Get an agent, and you immediately have a pathway to a career in writing. Remember, we all work on commission here so that would be the perfect reality. However, that is far from the truth.
When we sign on with an author, we see something in his or her writing. The project may be something that really hit home with us. Maybe they have a voice that is a once in a lifetime voice. It could be anything. However, we also have to remember that in the publishing world, everything is subjective, and every book is always on a case-by-case basis. In other words, just because I like the project does not mean that an editor will love it, or that there is even a place for it in the world right now.
I remember sitting at a conference listening to the amazing Steve Berry talk about his career. It took 5 full novels, even with an agent before his first book sold. Even then, it sold as a hunch on the part of the editor. There was apparently another author who was launching a book and the publisher thought that maybe adding a second book to this other up and coming author might work. That author had this story about DiVinci and some sort of code. What a deal!
The point is that we keep trying. If an agent doesn't sell your first book to an editor, it does not mean the agent is not doing his or her job. It is just that your book is not ready yet. It might never sell but it may be book 6 that does.