Here’s a link that may have answers to your question.
Hope this Helps..
It is simple to backup registry. Open Run menu, type regedit. Once Regedit opens go to File and Export- I would suggest a flash drive or other external storage. Depending on how badly you messed up your computer is how hard restoring it will be. If it is still operational do the same process but import instead of export. If it is not operational view comment above and hope you saved it externally. As for certain programs, that gets difficult and is very time consuming but can be done.
When you open regedit and have computer highlighted and export, that is exporting all the reg keys. If you highlight HKEY_CLASSES_ROOT and export, only the keys within that subfolder are exported. Therefore, if you find all the regestry keys associated to a program you could export them individually and if something goes wrong, restore them individually. Problem is that there is no cmd to select multiple files, it would take a long long time.
If you dont want to do it yourself use RegSnap Basically just takes snapshots of registry entries and compares them against one another.