Hi,
One condition known to affect weight is thyroid disease. A thyroid deficiency can cause a decrease in metabolism and may lead to weight gain.There are any number of drugs that may have weight gain as a side effect for some people. Some common ones include hormonal medications for birth control or menopause, oral steroids, some anti-depressants, diabetes medications and anti-psychotic medications.
If you have these ruled out these then it could be because you are not exercising enough, stressed, not sleeping enough or over-eating.
The only way to lose weight is to eat lesser calories than what you are using everyday.
For weight loss, you'll need to get about 5 cardio workouts each week at a medium-high intensity for at least 30 minutes.In addition to your cardio workouts, you'll need to lift weights for all your muscle groups at least 2 non-consecutive days a week.
ref:http://exercise.about.com/od/weightloss/ss/notlosingweight_8.htm