コード例 #1
0
    /// <summary>
    /// 导入校历信息
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void BtnImportCalendar_Click(object sender, EventArgs e)
    {
        AddSQLStringToDAL.DeleteTab("TabCalendar");
        lbMessage3.Text = "正在对数据进行初始化处理...";
        string filePath = Upload(FileUpload2);

        if (filePath != null && filePath.Length != 0)
        {
            lbMessage3.Text = ExcelToDatabase.CheckFile(filePath, "TabCalendar");
        }
        else
        {
            lbMessage3.Text = "您选择的文件不符合规范";
        }
    }