コード例 #1
0
        /// <summary>
        /// 页面载入响应
        /// </summary>
        protected void Page_Load(object sender, EventArgs e)
        {
            if (ServerListConfig.DataList.Count == 0)
            {
                return;
            }

            Response.ContentType = "application/x-msdownload";
            string filename = "attachment; filename=" + "GMTActivityTable.zip";

            Response.AddHeader("Content-Disposition", filename);
            Response.BinaryWrite(CdnZip.PackTable(Request.Params["version"]));
        }
コード例 #2
0
        /// <summary>
        /// 发送ZIP包按钮点击响应
        /// </summary>
        protected void sendButton0_Click(object sender, EventArgs e)
        {
            if (ServerListConfig.DataList.Count == 0)
            {
                this.errorLabel.Text = TableManager.GMTDescTable[657].desc;
                return;
            }

            FTPManager.Upload("updateex_" + ServerListConfig.DataList[0].Name + ".zip", CdnZip.PackTable(this.versionTextBox.Text));
        }