I normally hate saying 'read this tutorial' but pathfinding is a big and complex issue as you are able to make it, in other words the answer for you is based upon your skill and there's so many answers I cannot begin to start detailing a responce.
Here's a list of pathfinding tutorials which should enable you to choose one that you are able to code for yourself:
http://www.gamedev.net/reference/list.asp?categoryid=18#94
Pneumatic Dryll, Outrageous epic cleric of EQ/Xev
God made the world in 7 days, but we're still waiting for the patch.