Click here to Skip to main content
15,886,807 members
Articles / Desktop Programming / ATL

Increment File and Product Version Number - Multiple IDE

Rate me:
Please Sign up or sign in to vote.
4.58/5 (32 votes)
21 Oct 2008CPOL12 min read 290.7K   1.2K   134  
An add-in to automatically increment the FileVersion and ProductVersion fields in your application's resource file. Works in VC6 and VS2005, and probably all versions in between.
/**
 * \file IncVersion.idl
 *
 * \brief IDL for the IncVersion COM server
 *
 * $Id: IncVersion.idl,v 1.1.1.1 2006/09/24 23:12:32 mgh Exp $
 *
 *
 * Copyright (C) 2006 Michael G. Herstine <sp1ff@pobox.com>
 *
 * Permission to use, copy, or modify this source code is hereby granted
 * free of charge, provided that this copyright notice appear on all
 * copies and on all source code derived from this code.  No
 * representation is made regarding the suitability of this software for
 * any purpose.  It is provided "as is" without express or implied
 * warranty.
 *
 *
 * This file will be processed by the MIDL tool to produce the type
 * library (IncVersion.tlb).  There is no marshalling code.
 *
 *
 */

////////////////////////////////////////////////////////////////////////////
// Modified by Jordan Walters, 01.03.2008 for multi-IDE version increment //
////////////////////////////////////////////////////////////////////////////

import "oaidl.idl";
import "ocidl.idl";

#include "olectl.h"

[
	uuid(d52156f9-3d13-40c6-9d4d-24e18866f773),
	version(1.0),
	helpstring("Type Library for the Increment Version AddIn")
]
library IncVersionLib
{
	importlib("stdole2.tlb");

	[
		uuid(b69bfd01-851a-4401-bcfd-1151cfa5e108),
		helpstring("Increment Version AddIn Add-In Object")
	]
	coclass CoAddIn
	{
		[default] interface IUnknown /*IDSAddIn*/;
	}

	[
		uuid(05654755-8f5c-435f-a226-8c119b687eab),
		helpstring("Increment Version DevStudio 6 AddIn Object"),
		noncreatable
	]
	coclass CoDSAddIn
	{
		[default] interface IUnknown /*IDSAddIn*/;
	}

	[
		uuid(fa706fa7-506c-4e96-9be7-ba83fd298934),
		helpstring("CoDSAddIn Commands Interface"),
		dual
	]
	interface IDSCommands: IDispatch
	{
		[id(100), helpstring("Increment the Version")]
		void IncVersion();
		[id(101), helpstring("Configure the AddIn")]
		void Configure();
	}

	[
		uuid(226a69d3-6f1a-4533-870e-b55b1a874cec),
		helpstring("DevStudio 6 Commands object for the Increment Version AddIn"),,
		hidden,
		noncreatable
	]
	coclass CoDSCommands
	{
		[default] interface IDSCommands;
	}

	[
		uuid(705f31e4-ea39-44f6-b321-14c1bd782dab),
		helpstring("DevStudio 6 Application Events Sink for the Increment Version AddIn"),
		noncreatable,
		hidden
	]
	coclass CoDSAppEvents
	{
		[default] interface IDispatch; /* IApplicationEvents */
	};

	[
		uuid(e4a5d3b0-27e5-448d-9d20-b06060c80c63),
		helpstring("Increment Version AddIn DTE-Compatible AddIn"),
		noncreatable
	]
	coclass CoDTEAddIn
	{
		[default] interface IDispatch;
	}

	[
		uuid(f8e9744f-84bb-428f-bd6f-1eed32362849),
		control,
		helpstring("CoPropPageCtl Class")
	]
	coclass CoPropPageCtl
	{
		[default] interface IUnknown;
	};
}; // End library IncVersionLib.

// Local Variables:
// fill-column: 72
// indent-tabs-mode: nil
// show-trailing-whitespace: t
// End:

// IncVersion.idl ends here.

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer (Senior)
United Kingdom United Kingdom
Ok, it's about time I updated this profile. I still live near 'Beastly' Eastleigh in Hampshire, England. However I have recently been granted a permamant migration visa to Australia - so if you're a potential employer from down under and like the look of me, please get in touch.
Still married - just, still with just a son and daughter. But they are now 8 and 7 resp and when together they have the energy of a nuclear bomb.
I worked at Teleca UK for over 8.5 years (but have now moved to TikitTFB) and have done loads of different things. Heavily involved with MFC, SQL, C#, The latest is ASP.NET with C# and Javascript. Moving away from Trolltech Qt3 and 4.
Jordan.

Comments and Discussions