I learned how to record the window layout with register, but I also want it to be recorded for next time. but I would like to record this for next time I use emacs. How to do this?
With workgroups2, windows configurations can be stored in a workgroup, and you can create as many workgroups and named it; later, you can switch back. Because you can name your window configurations, you don't have the burden to remember which to which in registers. You can also save your window configurations to continue using them in later Emacs sessions.
You can issue a command to save current session with workgroup2.