最后是经理评分窗体中写的代码
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace 经理评分系统
{
public partial class FrmJudge : Form
{
//保存父窗体的实例
public FrmShow myParent;
//要评价的员工对象
private SE se;
//参数:父窗体的实例、被评分的员工在员工数组中的位置
public FrmJudge(FrmShow fparent,int index)
{
InitializeComponent();
this.myParent = fparent;
this.se = myParent.engineer[index];
}
private void FrmJudge_Load(object sender, EventArgs e)
{
//窗体加载,显示要评价的员工的姓名和得分等信息
this.txtName.Text = se.Name;
this.txtPingJia.Text = se.Assess;
this.txtPingFen.Text = se.MScore.ToString();
}
//点击评分按钮响应事件
private void btnPingFen_Click(object sender, EventArgs e)
{
try
{
PM pm = new PM();
pm.Judge(se,this.txtPingJia.Text.Trim(),Int32.Parse(this.txtPingFen.Text.Trim()));
//刷新主窗体
this.myParent.UpdateView();
this.Close();
}
catch (Exception ex)
{
MessageBox.Show("评分失败!"+ex.ToString());
}
}
private void btnCancel_Click(object sender, EventArgs e)
{
this.Close();
}
}
}
以上所述是小编给大家介绍的基于C#编写经理评分系统,希望对大家有所帮助,如果大家有任何疑问请给我留言,小编会及时回复大家的。在此也非常感谢大家对ASPKU网站的支持!
注:相关教程知识阅读请移步到c#教程频道。










