Exemplo n.º 1
0
 /// <summary>
 /// 输出word文档
 /// </summary>
 public void MakeWordDoc(string selectcommand, string filename)
 {
     if (InitData(selectcommand))           //从数据库中选择要导出的教学进度
     {
         InitInfo();                        //将数据库中的记录导入到对象数组中
         WordTools tools = new WordTools();
         tools.fullclasses(Info, filename); //将对象数组写进word文档
     }
     else
     {
         MessageBox.Show("没有找到指定数据");
     }
 }
Exemplo n.º 2
0
        public void SentPlacement()
        {
            WordTableInfo Info = InitializeWordInfo();//对象初始化
            WordTools Tool = new WordTools();
            List<string> ListSupervisor = new List<string>();//存放督导成员
            List<string> ListFileName = new List<string>();

            EmailInfo EInfo = new EmailInfo();
            SqlHelper help = new SqlHelper();
            List<string> ListAddress = new List<string>();
            DistinctSupervisor(Info.Supervisor, ListSupervisor);//分解出每个督导员
            FillWordTable(ListSupervisor,Info,Tool,ListFileName);//填写相应的word表格
            FindEmailAddress(ListSupervisor,help,ListAddress);//找到每个人的邮箱地址
            MakeEmail(EInfo,ListFileName,ListAddress,help,ListSupervisor);//发邮件
        }
Exemplo n.º 3
0
        public void SentPlacement()
        {
            WordTableInfo Info           = InitializeWordInfo(); //对象初始化
            WordTools     Tool           = new WordTools();
            List <string> ListSupervisor = new List <string>();  //存放督导成员
            List <string> ListFileName   = new List <string>();

            EmailInfo     EInfo       = new EmailInfo();
            SqlHelper     help        = new SqlHelper();
            List <string> ListAddress = new List <string>();

            DistinctSupervisor(Info.Supervisor, ListSupervisor);               //分解出每个督导员
            FillWordTable(ListSupervisor, Info, Tool, ListFileName);           //填写相应的word表格
            FindEmailAddress(ListSupervisor, help, ListAddress);               //找到每个人的邮箱地址
            MakeEmail(EInfo, ListFileName, ListAddress, help, ListSupervisor); //发邮件
        }
Exemplo n.º 4
0
 private void FillWordTable(List <string> ListSupervisor, WordTableInfo Info, WordTools Tool, List <string> ListFileName)
 {
     for (int i = 0; i < ListSupervisor.Count; i++)
     {
         if (i == 0)
         {
             Info.Supervisor = ListSupervisor[0];
             // ListFileName.Add(Tool.Addchiefsupervisordata(Info));
             ListFileName.Add(Tool.fullcheifsupervisor(Info));
         }
         else
         {
             Info.Supervisor = ListSupervisor[i];
             // ListFileName.Add(Tool.Addsupervisordata(Info));
             ListFileName.Add(Tool.fullsupervisor(Info));
         }
     }
 }
Exemplo n.º 5
0
 private void FillWordTable(List<string> ListSupervisor,WordTableInfo Info,WordTools Tool,List<string> ListFileName)
 {
     for (int i = 0; i < ListSupervisor.Count; i++)
     {
         if (i == 0)
         {
             Info.Supervisor = ListSupervisor[0];
            // ListFileName.Add(Tool.Addchiefsupervisordata(Info));
             ListFileName.Add(Tool.fullcheifsupervisor(Info));
         }
         else
         {
             Info.Supervisor = ListSupervisor[i];
            // ListFileName.Add(Tool.Addsupervisordata(Info));
             ListFileName.Add(Tool.fullsupervisor(Info));
         }
     }
 }
Exemplo n.º 6
0
 /// <summary>
 /// 输出word文档
 /// </summary>
 public void MakeWordDoc(string selectcommand,string filename)
 {
     if (InitData(selectcommand)) //从数据库中选择要导出的教学进度
        {
        InitInfo();//将数据库中的记录导入到对象数组中
        WordTools tools = new WordTools();
        tools.fullclasses(Info, filename);//将对象数组写进word文档
        }else{
        MessageBox.Show("没有找到指定数据");
        }
 }