About system restore

G

George

In Windows XP there is system restore function. I check the system restore
in MSDN, there are two functions about the system restore. One is
SRRemoveRestorePoint() and the other is SRSetRestorePoint().
I see the SRSetRestorePoint() function, it says "Specifies the beginning and
the ending of a set of changes so that System Restore can create a restore
point".
1. In the code sample of the MSDN, it says the beginning of the restore
point should be marked. What does the beginning restore point do when it
marked. I see it already create the restore point, and I use the file
monitor, it also save the files in the _restore folder.
2. In the code sample of the MSDN, at the end it marked the ending of the
restore point. What does the end do?I see nothing in the File monitor
function. And if I not end the restore point it seems also no effect about
the system restore.
3. If I use the system restore in the Windows XP, not use code, what does it
really do in the OS? Does it alse have the begin and end system restore
point?

I guess in the system restore, if I set the beginning of the restore point,
it then create the restore point, and save the protected file. If I set the
ending of the restore point, it then to check the saved file when at the
beginning poing setted, if changed it will save the unchanged and changed
file, this situation just like install the drivers and so on. If no ending
of the restore poing set, it just save the file in the XML list, this
situation just like to use the Windows XP UI to set the system restore. Am I
right?

Where I can find the resource about the syetem restore, I find it in the
MSDN, but i still have some puzzles.
 
R

Ramesh [MVP]

Hi George,

I'm not a SDK guy, but the MSDN article titled "Calling SRSetRestorePoint" explains more:

An application can create an install point before it causes a significant system change, such as an install, uninstall, or feature update.

To create a restore point just prior to installation, call the SRSetRestorePoint function with the dwEventType member of the RESTOREPOINTINFO structure set to BEGIN_SYSTEM_CHANGE. To notify System Restore that the installation has been completed, call SRSetRestorePoint with dwEventType set to END_SYSTEM_CHANGE.

After the END_SYSTEM_CHANGE, the control is passed on to the installer afaik.

You might get more accurate responses to this question if you try the SDK newsgroup. Or, wait for someone like David Candy to explain this further.

microsoft.public.platformsdk.shell


--
Ramesh, Microsoft MVP
Windows XP Shell/User
http://www.mvps.org/sramesh2k

Windows 2000 Group Policy Registry Table:
http://www.microsoft.com/windows2000/techinfo/reskit/en-us/gp/gpref.asp

In Windows XP there is system restore function. I check the system restore
in MSDN, there are two functions about the system restore. One is
SRRemoveRestorePoint() and the other is SRSetRestorePoint().
I see the SRSetRestorePoint() function, it says "Specifies the beginning and
the ending of a set of changes so that System Restore can create a restore
point".
1. In the code sample of the MSDN, it says the beginning of the restore
point should be marked. What does the beginning restore point do when it
marked. I see it already create the restore point, and I use the file
monitor, it also save the files in the _restore folder.
2. In the code sample of the MSDN, at the end it marked the ending of the
restore point. What does the end do?I see nothing in the File monitor
function. And if I not end the restore point it seems also no effect about
the system restore.
3. If I use the system restore in the Windows XP, not use code, what does it
really do in the OS? Does it alse have the begin and end system restore
point?

I guess in the system restore, if I set the beginning of the restore point,
it then create the restore point, and save the protected file. If I set the
ending of the restore point, it then to check the saved file when at the
beginning poing setted, if changed it will save the unchanged and changed
file, this situation just like install the drivers and so on. If no ending
of the restore poing set, it just save the file in the XML list, this
situation just like to use the Windows XP UI to set the system restore. Am I
right?

Where I can find the resource about the syetem restore, I find it in the
MSDN, but i still have some puzzles.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

About the system restore. 7
System restore never works 1
System Restore 1
Need help with System Restore 3
System Restore Question 1
Another "System Restore" Question 5
System Restore 4
system restore 9

Top