EmpPicDown.aspx.cs
上传用户:autodoor
上传日期:2022-08-04
资源大小:9973k
文件大小:1k
- using System;
- using System.Collections;
- using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Web;
- using System.Web.SessionState;
- using System.Web.UI;
- using System.Web.UI.WebControls;
- using System.Web.UI.HtmlControls;
- using System.Data.SqlClient;
- using System.Drawing.Imaging;
- using System.IO;
- using qminoa.BLL;
- using qminoa.Common.Data;
- namespace qminoa.Webs.MR
- {
- public class EmpPicDown : System.Web.UI.Page
- {
- private void Page_Load(object sender, System.EventArgs e)
- {
- int empID =Convert.ToInt16( Request.Params["empid"],10);
- DataRow rowEmp;
- try
- {
- DataTable empPicTB = (new EmpSystem()).GetEmpPicTB(empID);
- rowEmp = empPicTB.Rows[0];
- }
- catch
- {
- return;
- }
- Response.ContentType = "image/pjepg";
- Response.OutputStream.Write((byte[])rowEmp[EmpBaseData.PHOTO_CONTENT_FIELD],0,(int)rowEmp[EmpBaseData.PHOTO_SIZE_FIELD]);
- Response.End();
- }
- #region Web Form Designer generated code
- override protected void OnInit(EventArgs e)
- {
- //
- // CODEGEN:该调用是 ASP.NET Web 窗体设计器所必需的。
- //
- InitializeComponent();
- base.OnInit(e);
- }
-
- /// <summary>
- /// 设计器支持所需的方法 - 不要使用代码编辑器修改
- /// 此方法的内容。
- /// </summary>
- private void InitializeComponent()
- {
- this.Load += new System.EventHandler(this.Page_Load);
- }
- #endregion
- }
- }