Dose anyone know how to code a project to save its self to a file?

Any Help Would Be Great, Thanks