⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 optsoftwareview.cpp

📁 vc编程实现bp神经网络
💻 CPP
字号:
// OptSoftWareView.cpp : implementation of the COptSoftWareView class
//

#include "stdafx.h"
#include "OptSoftWare.h"

#include "OptSoftWareDoc.h"
#include "OptSoftWareView.h"

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

/////////////////////////////////////////////////////////////////////////////
// COptSoftWareView

IMPLEMENT_DYNCREATE(COptSoftWareView, CFormView)

BEGIN_MESSAGE_MAP(COptSoftWareView, CFormView)
	//{{AFX_MSG_MAP(COptSoftWareView)
	//}}AFX_MSG_MAP
	// Standard printing commands
	ON_COMMAND(ID_FILE_PRINT, CFormView::OnFilePrint)
	ON_COMMAND(ID_FILE_PRINT_DIRECT, CFormView::OnFilePrint)
	ON_COMMAND(ID_FILE_PRINT_PREVIEW, CFormView::OnFilePrintPreview)
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// COptSoftWareView construction/destruction

COptSoftWareView::COptSoftWareView()
	: CFormView(COptSoftWareView::IDD)
{
	//{{AFX_DATA_INIT(COptSoftWareView)
		// NOTE: the ClassWizard will add member initialization here
	//}}AFX_DATA_INIT
	// TODO: add construction code here

}

COptSoftWareView::~COptSoftWareView()
{
}

void COptSoftWareView::DoDataExchange(CDataExchange* pDX)
{
	CFormView::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(COptSoftWareView)
		// NOTE: the ClassWizard will add DDX and DDV calls here
	//}}AFX_DATA_MAP
}

BOOL COptSoftWareView::PreCreateWindow(CREATESTRUCT& cs)
{
	// TODO: Modify the Window class or styles here by modifying
	//  the CREATESTRUCT cs

	return CFormView::PreCreateWindow(cs);
}

void COptSoftWareView::OnInitialUpdate()
{
	m_database= new CDaoDatabase;
	try
	{
		m_database->Open("data.mdb");
		m_recordset=new CDaoRecordset(m_database);
	}
	catch (CDaoException* e)
	{
		e->ReportError();
		delete m_database;
		m_database=NULL;
		e->Delete();
		return;
	}
	CFormView::OnInitialUpdate();
	GetParentFrame()->RecalcLayout();
	ResizeParentToFit();

}

/////////////////////////////////////////////////////////////////////////////
// COptSoftWareView printing

BOOL COptSoftWareView::OnPreparePrinting(CPrintInfo* pInfo)
{
	// default preparation
	return DoPreparePrinting(pInfo);
}

void COptSoftWareView::OnBeginPrinting(CDC* /*pDC*/, CPrintInfo* /*pInfo*/)
{
	// TODO: add extra initialization before printing
}

void COptSoftWareView::OnEndPrinting(CDC* /*pDC*/, CPrintInfo* /*pInfo*/)
{
	// TODO: add cleanup after printing
}

void COptSoftWareView::OnPrint(CDC* pDC, CPrintInfo* /*pInfo*/)
{
	// TODO: add customized printing code here
}

/////////////////////////////////////////////////////////////////////////////
// COptSoftWareView diagnostics

#ifdef _DEBUG
void COptSoftWareView::AssertValid() const
{
	CFormView::AssertValid();
}

void COptSoftWareView::Dump(CDumpContext& dc) const
{
	CFormView::Dump(dc);
}

COptSoftWareDoc* COptSoftWareView::GetDocument() // non-debug version is inline
{
	ASSERT(m_pDocument->IsKindOf(RUNTIME_CLASS(COptSoftWareDoc)));
	return (COptSoftWareDoc*)m_pDocument;
}
#endif //_DEBUG

/////////////////////////////////////////////////////////////////////////////
// COptSoftWareView message handlers

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -