Rollback Command

See Also

Eliminates all changes since an earlier version of a file.

To use the Rollback command:

  1. Select a file in the file pane of VSS Explorer.

  2. On the Tools menu, click Show History.

  3. Make selections in the File History Options dialog box, if it is enabled.

    Note   Enable the display of the File History Options dialog box on the Command Dialogs tab in the SourceSafe Options dialog box (Tools menu).

  4. Select a previous version of the file, and then click Rollback.  When you rollback a file, you will lose all changes made to that file after the version you roll back to.  For example, if you click on version 5 and then click Rollback, all changes since version 5 are lost.

Access Rights

You must have the Destroy access right to use this command.

Remarks

Rollback returns a file to a previous version, erasing all the versions and changes since then; all changes made after the version rolled back to are lost.  The Rollback command cannot be reversed.

If the file you roll back is being shared by more than one project, the rollback affects only the project you specify (the current project, by default).  To accomplish this, Rollback performs an implicit branch, that is, it branches the file in the specified project away from the same file in all other projects, and creates a new development path.  To bring the disparate development paths back together, if you make changes to the specified project, you have to merge the files.

There are workarounds for undoing a rollback.  For a shared file, you can delete the resulting file and re-share it from another project.  For an unshared file, if you do not want to lose all the intervening steps, one method is to check out the file, get an earlier version, then check in the file.  The earlier version you get then becomes the most recent version, but no information is lost.