Home > Uncategorized > Using Visual SourceSafe – VSS in Visual Studio 2005 & 2008

Using Visual SourceSafe – VSS in Visual Studio 2005 & 2008

Using Visual SourceSafe – VSS in Visual Studio 2005 & 2008

Topics covering

  1. Choosing SourceSafe as the SCC Provider in Visual Studio
  2. Adding Solution into Source Control of SourceSafe
  3. Performing SourceSafe Operations in Visual Studio
  4. Changing Source Control Binding
  5. Pending Check-ins Window
  6. Viewing Source Control Message

Visual SourceSafe can be integrated into Visual Studio to source control solution files, project files and application configuration files. Using SourceSafe in Visual Studio allows us to source control the code directly in the Visual Studio IDE. When we try to modify a file source controlled by SourceSafe in Visual Studio, it will check out the file automatically (If you use the default setting Check out automatically for Checked-in item behavior On Edit in menu Tools -> Options -> Source Control -> Environment). We can then check-in the modifications into the VSS Database.

Choosing SourceSafe as the SCC Provider in Visual Studio

To use SourceSafe to source control your files in Visual Studio, you need to select SourceSafe as your source control provider first. You can do that through the Visual Studio menu Tools -> Options-> Source Control.


(Choose Source Control Provider)

Adding Solution into Source Control of SourceSafe

The files must be added into Source Control of SourceSafe before you can perform SourceSafe operations on them. To add a solution or project into VSS DB, right-click a solution/project files in Solution Explorer and click Add Solution to Source Control. In the following dialog boxes, enter your credentials and select a location for your project.

Performing SourceSafe Operations in Visual Studio

Now if you right-click an item in Solution Explorer or click menu File -> Source Control, you will see some additional SourceSafe functions, such as Get, Check Out/In, Undo Check Out, Compare etc.


(Access SourceSafe functions through right mouse button)


(Access SourceSafe functions through File menu)

View History
To view the history information of an item, you can right-click the item and select View History. You can perform operations like Check Out, Get, Pin in the History Explorer.


(History Explorer)

Changing Source Control Binding

If the project structure in SourceSafe has been changed, or the project has been moved to a new VSS DB, then you will need to change the source control binding of the solution. Go to menu File -> Source Control ->Change Source Control, perform Unbind to remove the solution/project from source control and then perform Bind to associate the solution/project with the recent server folder or database.


(Change source control binding)

Pending Check-ins Window

Visual Studio provides a Pending Check-ins Window which allows you to see all of the checked out files in the current solution. You can select items to check-in in the Pending Check-ins window. To open it, click menu View -> Pending Check-ins.

Viewing Source Control Message

In cases, when source control operations failed due to some reason, you may get confused by the vague error message(s) prompted by Visual Studio. In this situation, you may take a look at the Output Window of Visual Studio. If it is not already open, you can click menu View -> Output to open the window, choose to view the output message of Source Control and you can find more detailed information there.

Advertisements
Categories: Uncategorized
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: