资 源 简 介
Visual C# 通过调用存储过程显示客户的订单金额,获取客户的订单总额(获取存储过程参数的返回值):
private void button1_Click(object sender, EventArgs e)
{//获取客户的订单总额(获取存储过程参数的返回值)
DataClasses1DataContext MyDataContext = new DataClasses1DataContext();
string MyCustomer = "alfki";
decimal? MyAmount = 0;
MyDataContext.CustOrderTotal(MyCustomer, ref MyAmount);
MessageBox.Show(MyCustomer+"客户的订单金额是:"+MyAmount.ToString(),"信息提示",MessageBoxButtons.OK);
}