VC++6.0 Instructions for Use
How to write a program using vc++6.0
1. The menu of vc++6.0 is concise and the tools are clear. Here we take a hello world program as an example to illustrate the basic steps of programming. After running vc++6.0, click "File" - "New".
2. The "New" window is also very concise. It mainly contains two parts. The right side is the project name and the path where the project file is saved. The left side is the project type to be created. I have marked the commonly used ones in the picture. They are explained as follows:
1. Win32 console application: It is a win32 console program. Windows has two types of programs, one is the console program and the other is the graphics program. This is specified by the linker. Generally, novices start from learning C++ syntax. Hello in the example The world program also starts here.
2. Win32 application: win32 application. This type of project is generally established when learning windows programming, mainly to understand the graphics knowledge of windows.
3. mfc appwizd(exe): MFC application. After understanding the basics of windows graphics programming, a very important learning content is mfc. Although mfc is very old, learning it is essential for integrating windows graphics development and understanding the use of c++ classes. It is very helpful to use it on the windows platform, and it is generally used when working on C++ projects.
4. win32 dynamic-link libaray: win32 dynamic library is simply a project for writing DLL files. DLL is a dynamic link library file. It is a linking technology after static libraries. It can make the code more efficient. This is generally Used to encapsulate code when doing large projects.
3. Here we are using the hello world program as an example. Select win32 console application as the project type and name the project hello.
4. Choose to create "an empty project". The so-called empty project means that there are no program files. When you need to write code in the future, you need to create the corresponding header files and source code files, and then add them to the project.
5. Then click "File" - "New" again and select "C++ source File" to create a C++ source file. In addition, the commonly used one is "C++ header file", which is a C++ header file. By default, it is automatically added to the project, as shown in the figure below.
6. Next, write a C++ version of the hello world program in the newly created C++ source code file. The normal C/C++ programming process is: edit - compile - link build - execute.
Editing: writing source code and using C/C++ to describe the execution flow and algorithm of the program.
Compilation: Convert C/C++ source code into assembly language, and then use an assembly compiler to compile the assembly language into binary files. In VC++6.0, this program is cl.exe (it can be found in the installation directory of vc++6.0).
Link building: Each program uses many library files. The linker needs to merge the libraries and compiled application files into a program that can be executed by the operating system. On Windows, it is an exe file. This process is called link building.
Execution of program: The process in which the user drives the operating system to execute the program, such as running qq
#include
Using namespace std;
int main()
{
cout<<"hello world!"<
return 0;
}
The description is as follows:
#include: This is the input and output header file of C++, similar to stdio.h in C language.
Using namespace std: Using namespace, a feature of C++ is namespace, because C++ is a programming language developed for large-scale applications, and namespace is a mechanism introduced to deal with the confusion of variable identifiers in large-scale applications.
int main(): main function. Every C/C++ program has a main function, which is called by the operating system. On Windows, it is called by Windows. Which program on Windows calls it? In fact, it is the startup function mainCRTStartup. ().
cout<<"hello world!"<
Return 0: It is the return value of the main function main. This value is returned to the operating system. Essentially, it is returned to the exit() function. There is an errorlevel environment variable in cmd, which is the saved value.
7. The editing is completed above, the next step is compilation, click "Build" - "Compile". After compilation, press the F7 key to link and build the program.
8. The next step is to run the program. You can use the shortcut key CTRL+F5. The above is mainly to understand how a C++ program is written. For practice, generally press CTRL+F5 directly to execute the program. When executed, it will automatically compile and link. .
9. You can see the execution effect after execution.
VC++6.0 shortcut keys
document
Ctrl+N New New project
Ctrl+O Open Open the file
Find
Ctrrl+F Search
Alt+F3/Ctrl+F pops up the search dialog box
F3 Find next
Shift+F3 Find the previous one
Ctrl+F3 to find the next one
Ctrl+Shift+F3 Find the previous one
Commonly used by editors
Ctrl+W displays ClassWizard, which is more commonly used in boundary surface programs
Ctrl+U letters are converted to lowercase (some VCs do not have settings)
Ctrl+Shift+U converts letters to uppercase (some VCs do not have settings)
Ctrl+S Save (It is strongly recommended to press it twice frequently when encoding to avoid regrets when the power fails, haha,
Ctrl+G jumps to line n in the file
Ctrl+Shift+G When the cursor is on a file name, jump directly to the specified file
Ctrl+H Replace
Ctrl+L Cut a line
Ctrl+} matches brackets (),{}
VC++6.0 FAQ
Question: Why does "Error spawning error" appear after installing VC++6.0?
Answer: Click VC "TOOLS" -> "Option" -> "Directories" to reset the path of "Excutable Fils, Include Files, Library Files, Source Files". In many cases, the drive letter may be different (for example, your VC is installed in C, but these paths are all in D), and it can be changed.
Question: What should I do if "cannot convert from int* to unsigned *:" appears when installing VC++6.0?
Answer: The value in Project-》Settings-》Optimization is set to Disable optimization
Question: What should I do if it crashes directly when I click on the open option in VC++6.0?
Answer: Please right-click the shortcut or the startup program in the installation directory and select Run as administrator.
VC++6.0 software features
1. VC++6.0 is based onWindowsVisual integration of operating systemsdevelopEnvironment is one of the necessary software for computers
2. It is composed of multiple components, such as editor, debugger, program wizard and other development tools, integrating everyone into one, convenient
3. After users install VC++6.0, they can run most software, games, etc. without opening failure.
4. VC++6.0 adopts full Chinese formatoperatePanel, convenient for users to read, use and operate
VC++6.0 software advantages
1. Simple operation and complete tools;
2. Various classification management functions;
3. Not only can it process MFC, but also STL and ATL;
4. Powerful code writing function, able to cope with various needs.
VC++6.0 installation steps
1. Download VC++6.0 from Huajun Software Park and unzip it to the current folder. Click on the exe application and select the installation option. The default is the first [Workstation Tools and Components], then [Next] .
2. At this time we come to the installation program interface, select [Continue] here.
3. After waiting for a moment, the installation path option will appear. Click [Change Folder] to change the installation path, and click [Big Button] to start the installation.
4. There may be no response during the installation process. Just choose to wait for the program. If anti-virus software such as 360 appears to intercept it, click Allow. When the shortcut appears in the start menu, the installation is basically complete. At this point, we can close the installation program that is still unresponsive.
Comparison of similar software
Delta plc programming softwareThe latest version is a PLC programming software for mechanical control management. The latest version of Delta's plc programming software can write some instructions with precise calculations, which are used to perfectly control and manage the mechanical production of the enterprise's production line. It uses a memory that can be programmed to store and execute logical operations inside it. Instructions for sequential operations, timing, counting, and arithmetic operations, and can control various types of machinery or production processes through digital or analog input and output.
Weilun touch screen software EasyBuilder8000 (EB8000 for short)It is a new generation of human-machine interface software developed by Taiwan Weilun Technology Co., Ltd. and is suitable for our company's MT8000 and All models of the MT6000 series.
Huajun editor recommends:
VC++6.0Users can also make the program framework generated by VC++ support database interface, OLE2, WinSock network and 3D control interface through simple settings. The operation steps of VC++6.0 software are very simple and very fast, so users can use it with confidence.
it works
it works
it works