I get alot of questions about pain in differant areas of the body when doing workouts on the treadmill. There are several reasons that this could be happening to you. Sometimes it is knee pain, sometimes hip pain, it doesnt matter. Pain is a sign from the body that you are doing something wrong.
Take a look at this video demonstration of improper treadmill workout form and see if you can see any of the mistakes that are being made.