Tip:
Highlight text to annotate it
X
hi all I am nader nour
we will learn today how to make a Gui interface with mfc
this tutorial is for the people who know object oriented and C++
ok then lets start :)
lets start the visual studio
New project--> windows 32 project
lets call it mfc
first of all we have to change the properites of the project
make use of MFC static library make the charachter set not set
we will creat today just an empty window to do so we need to make a class
to make some customization for this window press add --> class
ok? this class will be called "mywnd" of course u can call it any other name
lets add c and then.. the base clas will be cframewnd
lets click finish
it's asking if the CFramewnd is in your header files press yes
this something I learned from my doctor which is we make a header file we put in it the header files we will use and the one we will make
lets make then a header file lets name it an easy name I prefer cmn
we wil write in this header file the header we will use which the first one is the library of mfc
then we will add the library we made which is MyWnd.h
then we finished our cmn lets include it in Mywnd's Cpp
replace with cmn
we need to creat only an Empty Window then we will wright in the constractor function called creat
lets do it then lets give it null
then the name of the Window
then lets add our Main that we talked about before new item ----> .cpp
I already prepared the main
what did we do in this main? first thing we made an instant of CMyWnd pionter called....
then we make alocate in the memory for CMyWnd
then we make the pionter called mpmainwnd equel to our wnd which is defined in the CWnApp
then we use show window to show the window 7mada helal :D
now we have white Window Thanks For Watching