Why can't you just take a vitamin? Why you need a healthy diet on top of that?
I think the piece of missing information here is the distinction between macronutrients and micronutrients. The info from Mayo clinic quoted in the another answer addresses some reasons why whole foods might be better than pills for obtaining micronutrients (i.e. vitamins and minerals).  While this may be true, most of it remains to be conclusively demonstrated (arguably). However, one clear reason “why….you need a healthy diet on top of that” is (unarguably) to obtain the fat, protein, and carbohydrates that your body uses to create energy. Unlike the minerals that act as cofactors, these macronutrients are the substrate. They are broken down to create the ATP that keeps everything running and they are built up to create the very structure of the body. 


  The energy that is consumed in the form of food or drinks can either be stored in the body in the form of fat (the major energy store), glycogen (short-term energy/carbohydrate reserves), or protein. . . to be used by the body to fuel energy-requiring events. *


These are called macronutrients because they are required in gram quantities &mdash; hundreds or even thousands of times more massive than the requirements for most micronutrients. As such, they don’t fit in a pill. As tragic as it is, we must keep eating.  




*Gibney, M. J., &amp; Nutrition Society. (2009). Introduction to Human Nutrition. Chichester, West Sussex, U.K.: Wiley-Blackwell.