Source: http://blog.csdn.net/ljianhui/article/details/8781991In the process of MFC program design, the most uncomfortable, even sometimes shaking the learner's confidence is a process of all the details are not control of the feeling. This feeling comes from the learner does not know how an MFC program is running (that is, an MFC program execution process) and
Chapter 1 Overview Application Framework
1. Application Framework: we dig out a part of a complete set of modules (such as MFC and OWL) written by others, and give an application object to instantiate them one by one, some of these parts are allowed to be modified to make the program more suitable for personal needs. An extended collection of classes that cooperate to support a complete application architecture or application model, providing more co
I have used QT and MFC to develop software. I 'd like to share with you the differences I have experienced when using them.
I am not a professional writer. This article may seem less organized than professional magazines and websites. However, I want to share my experience with you in my own language. English is better than my native language. Therefore, some words may be odd and incorrect. Please send me a letter and I can correct them.
This article
MFC Program DesignThe ins and outsQuestion: I have been thinking about writing this thing some days ago. I started my blog with a name (but it is called Note: 1. The author of this article traces the code in vs2003. This code is copied in vs2003 and mfc7 is used.2. the MFC programs of different frameworks are different. This document takes a single document as an example.3. The reader of this article needs
Part Two: A simple MFC program
In this session, we will look at the MFC application mentioned in the previous section to understand its structure and conceptual framework. We'll introduce MFC first, and then we'll explain how to build an application with MFC.
Introduction to MFC
WTL are not what the framework, is the use of generic characteristics of the win API layer encapsulation, design ideas also did not get rid of the impact of MFC, in fact, with the generic UI framework can only be regarded as a behavioral art, the idea of continued development will become useless, such as The code is too complex, the compilation is too slow, error is not good debugging and other problems difficult to solve.And the package is not comple
Originated from http://my.oschina.net/ypimgt/blog/62573First, the preparatory workFirst step : Download and install Adobe Flash Player.Download the latest Flash Player (approximately 2.66M) from the official website (http://get.adobe.com/cn/flashplayer/) and install it. For WINDOWS 32-bit systems, the default installation directory is: C:\WINDOWS\system32\Macromed\Flash\; for 64-bit systems: C:\Windows\SysWOW64\Macromed\Flash.The large version number of the Flash control is represented by a numb
Xtrme Toolkit,Bcgcontrolbar,Skinmagic,Appface,skin++,uskin++,Sygui,libuidk,Guitoolkit,Gardenuiand so on, except the latter two are open source, one is free, the rest are charged. The Ultimate ToolboxHttp://www.codeproject.com/KB/MFC/UltimateToolbox.aspxGuitoolkit (open source,MFC extension Framework, similar to Visual Studio 2003 style)Http://www.beyondata.com/default.htmGardenui (free, very good interface
In terms of the programming hierarchy,Win32Is the bottom layer,SecondMFC.ThenATLAnd finallyCLR.
1.Win32Normally, it is unnecessary.MFC, UseAPIFunction CodeProgram; Win32 winapi can be called;
1) Win32 Application
2) Win32 console application
3) Win32 dynamic-Link Library
4) Win32 static library
2. MFC ( Microsoft Foundation Classes: Basic Microsoft class library ) The database has a history of many years,
Windows objects, handles, and MFC objects
(22:11:34)
Reprinted
Tags:Windows objectsHandleMFC objectMiscellaneous
Classification: MFC and Windows Programming
Windows objects are identified by handles. The corresponding MFC class is the c ++ packaging of these handles. Windows objects in the memory must be identified by a unique handle, but not nec
software was once the only place for VC. When C # Was just launched, it was regarded as a joke by many people.Net. Up till now, using C # To develop desktop software is still a minority, at least I have only one cable in my computerLove mobile phone management software. This situation will be rewritten because. net has been integrated into the operating system by default Since Vista started., Just like the previous mfcxx. dll and msvcrt. dll. Anyone who has used C # knows that C # is very conve
1. MFC rule dll mfc rule dll can be used inside the DLL, but the interface with the application cannot be MFC. It can be used by all applications that support DLL programming languages, including those created using MFC. This dynamic link library contains a class inherited from cwinapp, And the dllmain function is also
The Document view structure (Document/view architecture) is the essence of MFC and one of the concrete implementation frameworks for observer patterns, Document/view architecture by separating the data from its representation, Provides a good level of data and performance levels of decoupling. However, while using MFC AppWizard, we can easily get an MFC program
1, the reason is "possible", because there is a point is that the temporary object is the encapsulation of the HWND operation, not the window class encapsulation. Thus all hwnd temporary objects are instances of CWnd, even if the above forcibly converted to cabcdialog* is still cwnd*, so when Cabcdialog::assertvalid is called in Assert_valid, it defines some additional checks, It may be found that this is an instance of CWnd rather than an Cabcdialog instance, resulting in an assertion failure.
MFC encapsulates the win API. Everyone knows. But how many people know about the real process of MFC applications?
Here are some of my analysis of the MFC startup code.
In TCHAR.H, there are 2 small pieces of define. Through my simplification, we can see:
//TCHAR.H #ifdef _UNICODE #define _tWinMain wWinMain #else #define _tWinMain WinMain #endif
Because the W
In the past few days, I have discussed with a few foreigners what programming languages I use in the Forum. To my surprise, people like me who have been using MFC for more than 10 years have become monsters in their eyes. In addition, they recommend C # In the same voice #. A foreigner said that his previous project used MFC at the beginning, but the progress was very slow. Later he switched to C #, And the
Differences between MFC and Win32
MFC encapsulates winmain internal operations with relatively fixed behaviors in cwinapp, and wndproc internal operations with relatively fixed behaviors in cframewnd.
It can be said that cwinapp is used to replace winmain's position in the SDK program, and cframewnd replaces the position of window functions in the SDK program.
First, the
What's new for MFC developers? (Translation)
--------------------------------------------------------------------------------Author: kamphkb Source: http://msdn.microsoft.com/msdnnews/2001/sept/vcnet/vcnet.aspWhat's new for MFC developers?By Anson Tsao and Walter SullivanBy bar wanghai (kevin_kbh@21cn.com)[Translator: due to the time relationship, I omitted some detailed translations, but I still clicked on
Next)
VC advanced: 1. C language; 2. c ++, oop; 3. Windows operating mechanism, SDK programming; 4. MFC class library, Application Program Framework programming; 5. ActiveX, ATL, com ...... It usually takes six months for each step, and it may take up to three months. Do you agree?Learning VC or Windows programming is divided into three steps: 1. only functions provided by the SDK are used for development. Do not use objects. You will know how to han
MFC interface Packaging
-- The asserted call of the member function fails when multiple threads are used.
I often see the following problems on the Forum:DWORD winapi threadproc (void * pdata) // thread function (for example, used to obtain data from the comport){// Data acquisition cycle// Put the obtained data in variable ICabcdialog * pdialog = reinterpret_cast Assert (pdialog); // here assert_valid (pdialog) will assert failurePdialog-> m_data =
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.