计算算式字符串的

using System;
using System.Data;
using System.Windows.Forms;

namespace WindowsFormsApplication1
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            DataTable dt = new DataTable();

            Text = dt.Compute(textBox1.Text, "").ToString();
        }
    }
}

http://blog.csdn.net/qzyf1992/article/details/8967996

原文地址:https://www.cnblogs.com/xe2011/p/3474863.html