Click here to Skip to main content
15,891,184 members
Articles / Programming Languages / C#

An extensible math expression parser with plug-ins

Rate me:
Please Sign up or sign in to vote.
4.92/5 (147 votes)
13 Mar 2008CPOL51 min read 1.4M   29K   364  
Design and code for an extensible, maintainable, robust, and easy to use math parser.
// IndexDlg.cpp : implementation file
//

#include "stdafx.h"
#include "MathExpr.h"
#include "IndexDlg.h"

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

/////////////////////////////////////////////////////////////////////////////
// IndexDlg dialog


IndexDlg::IndexDlg(CWnd* pParent /*=NULL*/)
	: CDialog(IndexDlg::IDD, pParent)
{
	//{{AFX_DATA_INIT(IndexDlg)
	m_consts = _T("");
	m_funcs = _T("");
	m_ops = _T("");
	//}}AFX_DATA_INIT
}


void IndexDlg::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(IndexDlg)
	DDX_Text(pDX, IDC_DEFINEDCONSTS, m_consts);
	DDX_Text(pDX, IDC_DEFINEDFUNCS, m_funcs);
	DDX_Text(pDX, IDC_DEFINEDOPS, m_ops);
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(IndexDlg, CDialog)
	//{{AFX_MSG_MAP(IndexDlg)
		// NOTE: the ClassWizard will add message map macros here
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// IndexDlg message handlers

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Web Developer
Canada Canada
Software Engineer working at a fun and smart startup company

Comments and Discussions