Solutions in multi-engineering

zhaozj2021-02-16  86

Solutions in multi-engineering (VC 6.0)

The VC development environment is divided into .H and .CPP files separately store, declare in .h file, defined in .cpp files. We see the variables declared in the .h file in the ClassView file. Or method.

Note: Before the development, each group or person must coordinate the definition style of his resource ID, an example, in a project, two people simultaneously develop interface, one is the user interface, one is system resources, use DLG , Edit and other resources, then define the resource ID, the two ID names are different, the ID value is different, the two people's DLG can be defined: Define IDd_system_dialog1 51101Define IDD_SYSTEM_DIALOG2 51102DEFINE IDD_SYSTEM_DIALOG3 51103 ...

with

Define IDD_USER_DIALOG1 61101DEFINE IDD_USER_DIALOG2 61102DEFINE IDD_USER_DIALOG3 61103 ...

Other resources are also defined.

The engineering process of multi-person development is as follows: Assuming the SYSTEM project to use the USER engineering DLG, then assume that the csystemView in the SYSETM project is used to use the user's cuserdlg.cuserdlg's resource ID to: IDD_USER_DIALOG1

1. Place the System Engineering and the User Engineering File. 2, in csystemView.cpp, add #include "../user/cuserdlg.h"3, switch Workspace (Workspace) to switch under the VC interface Under FileView, right click on "Source File" -> "Add Files To Folder ..." Adds CUSERDLG.CPP under the User directory. 4, open STDAFX.H, add: #include "../user/resource.h" ../user/resource.h "5, open user.rc, and system.rc with other text editor, find IDD_USER_DIALOG1 in User.rc ((From IDD_USER_DIALOG1 to the nearest END) to copy it to the "#ifndef _mac" in the System.rc file. 6, in system.rc #include "resource.h", add #include "../user/resource.h" to do it! ! Note: 1, the RedInition warning may appear, which may be that the ID definition of the two projects has heavy, then go back to modify it 2, may include other files in cuserdlg.h, and these files will be included. CPP is also added to "Source Files" as in step 3.

转载请注明原文地址:https://www.9cbs.com/read-15743.html

New Post(0)