How can I lose weight, when I do not have a pituitary gland for energy from a tumor and my last surgery a crainiotomy?

Optimize hormones. If you have panhypopituitarism (no pituitary hormones), you will need several hormone replacements and achieving normal levels. If you are still feeling tired despite optimization of you pituitary hormones, your fatigue may be caused by processes unrelated to your pituitary. Either way, watching your diet and reducing your caloric intake can allow you to lose weight even if you don't exercise.
Like everybody else. Weight loss is a matter of using more calories than you take in, regardless of your other medical issues. You do want to make sure that you are adequately treated for any hormonal deficiencies though.