Thursday, January 15, 2009

Compilation Windows

Compilation is the stepping stone for any application to go from lines in some text to executable or some other thing (library, DLL,etc).

Whenever compilation starts one can look into the process, and what are the errors at the compilation time itself, and not to wait till the end of compilation showing "Build Failed".

Go To Tools >> Options



Projects & Solutions >> General

Check this two simple statements which will make your life very easy to see through the compilation process and the error types and information in cluster.

On setting the output window, it will automatically show one window which will be showing you the current project and in that, which file is getting compiled.

And Error List window is helpful, when there are more project files and few error messages, then instead of search the error in the output window, Visual Studio provides the feature which accumulates all the error messages that appeared in the current compilation and shows them in listed form.

Monday, January 12, 2009

Include Directories

The include directories are of great importance, they provide the header files required for the compilation of the application. If the path specified is not valid or pointed to wrong directory, compilation can be disastrous.

As many a times if wrong header file version comes into compilation, many valid function reference may become invalid. Also some times the function reference may not be able to find the function prototype or can not find the header file itself.

Hence, whenever you face an issue where a standard header file is not found or function reference is incorrect, just make sure the include paths are correct.

Go to Tools >> Options:




Projects and Solutions >> VC++ Directories

Select "Include" from Drop-Down Box.

You will see the include paths in list box.

Tuesday, January 6, 2009

Source (Version) Control Settings in Visual Studio IDE

Current post is on how to change source (version) control  settings in Visual Studio IDE.


Source (Version) control software is an essential tool in every software company. It not only keeps the track of the history, but also its version and copy of it.

Clearcase and SVN are most common source (version) control softwares available in market. Clearcase is a proprietary software from IBM while SVN is open-source software with good developer support.

When writing a code which will go into source control or when you want to edit something in a file which is in source control, we all do check-out and check-in operations.

Some times in hurry we check-out the file which were not meant for check-out, resulting in undo-check-out operation with version-branch-deletion of that file.

In order to avoid such things, Microsoft Visual Studio IDE (VS 2005, VS 2008) provides the source (version) control settings.

Go to Tools >> Options in Menu bar of Visual Studio IDE:

Visual Studio Source Control Settings
Source Control Settings
Click Source Control >> Environment

Check-Out Settings:

  1. On Save or On Edit:
    • Check Out Automatically or Prompt for Check out are the options available. Select as per your needs
    • "Don't show Check-Out dialog box while checking out the items":  
      • Un-Check the check-box, if you want to prevent above scenarios.
      • Check the check-box of if you are precised enough and don't want a headache of another prompt.

    Appreciate your feedback via comments. Thanks.

    Saturday, January 3, 2009

    Concurrent Builds

    In Visual Studio IDE, if one has more then one project in a solution with minimal dependency, one can opt for this "Concurrent Build" feature.

    Complier starts building the projects which are not dependent, in parallel. With Core-2-Duo, this thing gets a boost.

    So, to build the solution faster, just change the thing:

    Tools >> Options



    Projects and Solutions >> Build and Run to "Four"

    It is been tested and concluded that value "Four" is optimal.
    Disclaimer:

    The above post and all the posts in the blog are derived from facts, information, logical interpretation and logical conclusion of printed and internet materials available to me, perceived and produced by 99 gm brain of mine, which by no means always be accurate, consistent and complete.

    All the posts are for personal quick reference only.

    If any suggestion, correction, misinterpretation, misconception commented, which will be moderated and deleted if required, to avoid unforeseen issues.

    If any trademark / copywrite issue is present, do send in a mail and appropriate tag (logo, name, website link) will be attached to the same.

    Additional disclaimer will be attached wherever required in the post.