Does Vitamin D alone build bones? No, but it is essential for calcium absorption. Common forms of Vitamin D are D2, added to milk, D3 supplements, and the D that our bodies manufacture with sunshine on bare skin. Dr. Mercola, author of a popular health blog, recommends 15-20 minutes of sunshine as a superior means of obtaining Vitamin D or taking D3 supplements. His article covers the role of other supplements, diet, and lifestyle on osteoporosis.
Here's an informative article about the role of Vitamin D and Vitamin K in building bone density through calcium absorption.