Click here to Skip to main content
13,145,464 members (79,280 online)
Click here to Skip to main content


246 bookmarked
Posted 26 Sep 2002

VC++7 to VC++6 project converter

, 22 Oct 2003
This tool automatically converts Visual C++ 7.0 projects back to Visual C++ 6.0 projects.
#pragma once

// vcprojconfiguration class
// S.Rodriguez - Sept 2002
// purpose : fill class members with actual configuration data from the .vcproj file

class vcprojconfiguration
	FindableArray General;
	FindableArray VCCLCompilerTool;
	FindableArray VCLibrarianTool;
	FindableArray VCLinkerTool;
	FindableArray VCResourceCompilerTool;
	FindableArray VCMidlTool;
	FindableArray VCBscMakeTool;
	FindableArray VCPreBuildEventTool;
	FindableArray VCPreLinkEventTool;
	FindableArray VCPostBuildEventTool;
	FindableArray VCCustomBuildTool;
	FindableArray VCNMakeTool;
	FindableArray VCDebugSettingsTool;

// Constructor

// Accessors
	void setMasterProjConfigurations(vcprojconfiguration *p); // used for FileConfiguration
	CString getConfigName();
	BOOL hasVCConfigTool(CString &szToolName);

// Methods
	void fill(/*in*/IXMLDOMElement *p); // fill class members

	CString serializeCPPSymbols(BOOL bFileConfiguration=FALSE);
	CString serializeLinkerSymbols(BOOL bFileConfiguration=FALSE);
	CString serializeLibrarianSymbols(BOOL bFileConfiguration=FALSE);
	CString serializeResourceSymbols(BOOL bFileConfiguration=FALSE);
	CString serializeMidlSymbols(BOOL bFileConfiguration=FALSE);
	CString serializeBscMakeSymbols(BOOL bFileConfiguration=FALSE);
	void serializePreBuildCommands(/*out*/ArrayCString &output, BOOL bFileConfiguration=FALSE);
	void serializePreLinkCommands(/*out*/ArrayCString &output, BOOL bFileConfiguration=FALSE);
	void serializePostBuildCommands(/*out*/ArrayCString &output, BOOL bFileConfiguration=FALSE);
	void serializeCustomBuildCommands(/*out*/CString &szDescription, /*out*/ArrayCString &cmds, /*out*/ArrayCString &outputFiles, /*out*/ArrayCString &additionalDeps, BOOL bFileConfiguration=FALSE);

	// Helpers
	void fillFromAttributes(/*in*/IXMLDOMElement *p, /*out*/FindableArray &arrAttribs);
	void BSTR_to_CString(/*in*/BSTR bstr, /*out*/CString &s);
	void getAttribValue(/*in*/IXMLDOMElement *p,/*in*/char *szAttribName, /*out*/CString &szValue);
	void VARIANT_to_CString(/*in*/VARIANT &vt, /*out*/CString &s);
	void TokenizeString(/*in*/CString &szInput, char cToken, /*out*/ArrayCString &arrStrings);
	void TokenizeString(/*in*/CString &szInput, /*in*/CString &szTokenString, /*out*/ArrayCString &arrStrings);
	void UntokenizeString(/*in*/ArrayCString &arrStrings, char cToken, /*out*/CString &szOutput);
	CString ExpandMacros(/*in*/CString &szInputString);
	CString ReplaceMacros(/*in*/CString &szInputString, BOOL bReplaceBackslash=TRUE);

	// other class members
	vcprojconfiguration* m_cpParentConfigurations; // copy ptr

typedef CTemplateObjArray<vcprojconfiguration*> ConfigurationArray;

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.


This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


About the Author

Addicted to reverse engineering. At work, I am developing business intelligence software in a team of smart people (independent software vendor).

Need a fast Excel generation component? Try xlsgen.

You may also be interested in...

Permalink | Advertise | Privacy | Terms of Use | Mobile
Web03 | 2.8.170915.1 | Last Updated 23 Oct 2003
Article Copyright 2002 by Stephane Rodriguez.
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid