1) Is it shutting off or restarting?
2) Tell us about your computer (make, model, etc)
3) What is new or different since the last time everything worked properly (ie, new hw, new sw, virus, error, etc)?
Please give us as much relevant information as you can or we won't be able to offer any intelligent assistance.