I agree with Iburmaster--one excellent way to gain weight is to work out. Muscle is more dense than fat, and is therefore heavier. Also, the process of working out is good for your health in general--strength, stamina, your overall feeling of well being, etc.
Beyond that, your diet plays a huge factor in gaining weight, both healthy and unhealthy. As you're looking for the former, I would recommend a diet high in protein and carbohydrates. That will give your body what it needs to synthesize both muscle cells and modest reserves of body fat. If you start an exercise regimen, protein and carbs are especially important. For protein, think lean meats like chicken breast or fish, and when it comes to carbs, pasta and breads are your friend. If you're not into meat, tofu is a great protein base for meals, and peanut butter makes for a protein-rich snack.
Whatever you do, stay hydrated! The body requires water to digest proteins, and working out can take the fluid out of you. You may need to step up your fluid intake somewhat to adjust for lifestyle changes like these. I hope this helps.