Virtue is the quality of being morally good. If you're writing a screenplay and you want it to be a real tearjerker, make sure your hero is full of virtue.
The word virtue comes from the Latin root vir, for man. At first virtue meant manliness or valor, but over time it settled into the sense of moral excellence. Virtue can also mean excellence in general. One of your virtues might be your generous willingness to help out your friends. The phrase by virtue of means "as a result of" or "by authority of." You will achieve success by virtue of hard work (or by virtue of inside connections).