• 大小: 4.52MB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-09-17
  • 语言: C/C++
  • 标签: 通讯录  VC++  MFC  

资源简介

基于VC++MFC的通讯录程序设计 通讯录应用程序操作方法如下: 1.编译程序。 2.打开通讯录\debug\通讯录.exe程序。 3.进入应用程序主体,单击“add”按钮,添加一个新的记录信息,输入需要填入的信息。 4.选择工具栏处的向左和向右按钮,单击“delete”或“edit”按钮对记录信息进行删除或编辑。 5.单击“关闭”按钮退出程序。

资源截图

代码片段和文件信息

// MainFrm.cpp : implementation of the CMainframe class
//

#include “stdafx.h“
#include “ͨѶ¼.h“

#include “MainFrm.h“

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CMainframe

IMPLEMENT_DYNCREATE(CMainframe CframeWnd)

BEGIN_MESSAGE_MAP(CMainframe CframeWnd)
//{{AFX_MSG_MAP(CMainframe)
// NOTE - the ClassWizard will add and remove mapping macros here.
//    DO NOT EDIT what you see in these blocks of generated code !
ON_WM_CREATE()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()

static UINT indicators[] =
{
ID_SEPARATOR           // status line indicator
ID_INDICATOR_CAPS
ID_INDICATOR_NUM
ID_INDICATOR_SCRL
};

/////////////////////////////////////////////////////////////////////////////
// CMainframe construction/destruction

CMainframe::CMainframe()
{
// TODO: add member initialization code here

}

CMainframe::~CMainframe()
{
}

int CMainframe::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
if (CframeWnd::OnCreate(lpCreateStruct) == -1)
return -1;

if (!m_wndToolBar.CreateEx(this TBstyle_FLAT WS_CHILD | WS_VISIBLE | CBRS_TOP
| CBRS_GRIPPER | CBRS_TOOLTIPS | CBRS_FLYBY | CBRS_SIZE_DYNAMIC) ||
!m_wndToolBar.LoadToolBar(IDR_MAINframe))
{
TRACE0(“Failed to create toolbar\n“);
return -1;      // fail to create
}

if (!m_wndStatusBar.Create(this) ||
!m_wndStatusBar.SetIndicators(indicators
  sizeof(indicators)/sizeof(UINT)))
{
TRACE0(“Failed to create status bar\n“);
return -1;      // fail to create
}

// TODO: Delete these three lines if you don‘t want the toolbar to
//  be dockable
m_wndToolBar.EnableDocking(CBRS_ALIGN_ANY);
EnableDocking(CBRS_ALIGN_ANY);
DockControlBar(&m_wndToolBar);

return 0;
}

BOOL CMainframe::PreCreateWindow(CREATESTRUCT& cs)
{
if( !CframeWnd::PreCreateWindow(cs) )
return FALSE;
// TODO: Modify the Window class or styles here by modifying
//  the CREATESTRUCT cs

return TRUE;
}

/////////////////////////////////////////////////////////////////////////////
// CMainframe diagnostics

#ifdef _DEBUG
void CMainframe::AssertValid() const
{
CframeWnd::AssertValid();
}

void CMainframe::Dump(CDumpContext& dc) const
{
CframeWnd::Dump(dc);
}

#endif //_DEBUG

/////////////////////////////////////////////////////////////////////////////
// CMainframe message handlers


 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2013-04-29 10:45  通讯录\
     目录           0  2013-04-29 10:38  通讯录\Debug\
     文件       19834  2013-04-29 10:38  通讯录\Debug\MainFrm.obj
     文件           0  2013-04-29 10:38  通讯录\Debug\MainFrm.sbr
     文件      107223  2013-04-29 10:38  通讯录\Debug\StdAfx.obj
     文件     1456764  2013-04-29 10:38  通讯录\Debug\StdAfx.sbr
     文件      222208  2013-04-29 10:38  通讯录\Debug\vc60.idb
     文件      372736  2013-04-29 10:38  通讯录\Debug\vc60.pdb
     文件     3302400  2013-04-29 10:38  通讯录\Debug\通讯录.bsc
     文件      127027  2013-04-29 10:38  通讯录\Debug\通讯录.exe
     文件      355080  2013-04-29 10:38  通讯录\Debug\通讯录.ilk
     文件       22518  2013-04-29 10:38  通讯录\Debug\通讯录.obj
     文件     7235664  2013-04-29 10:38  通讯录\Debug\通讯录.pch
     文件      361472  2013-04-29 10:38  通讯录\Debug\通讯录.pdb
     文件        8468  2013-04-29 10:38  通讯录\Debug\通讯录.res
     文件           0  2013-04-29 10:38  通讯录\Debug\通讯录.sbr
     文件       18624  2013-04-29 10:38  通讯录\Debug\通讯录Doc.obj
     文件           0  2013-04-29 10:38  通讯录\Debug\通讯录Doc.sbr
     文件       20054  2013-04-29 10:38  通讯录\Debug\通讯录Set.obj
     文件           0  2013-04-29 10:38  通讯录\Debug\通讯录Set.sbr
     文件       28994  2013-04-29 10:38  通讯录\Debug\通讯录View.obj
     文件           0  2013-04-29 10:38  通讯录\Debug\通讯录View.sbr
     文件        2507  2012-09-21 13:02  通讯录\MainFrm.cpp
     文件        1581  2012-09-21 13:02  通讯录\MainFrm.h
     文件        4176  2012-09-21 13:02  通讯录\ReadMe.txt
     目录           0  2013-04-29 10:34  通讯录\res\
     文件        1327  2012-09-21 13:02  通讯录\resource.h
     文件        1198  2012-09-21 13:02  通讯录\res\Toolbar.bmp
     目录           0  2013-04-29 10:34  通讯录\res\新建文件夹\
     文件         398  2012-09-21 13:02  通讯录\res\新建文件夹\通讯录.rc2
     文件        1078  2012-09-21 13:02  通讯录\res\通讯录.ico
............此处省略21个文件信息

评论

共有 条评论