<%@ Page Language="C#" AutoEventWireup="true" %>

<script runat="server">

    protected void Page_Load(object sender, EventArgs e)
    {
        Aspx1.Common.ValidateCode gif = new Aspx1.Common.ValidateCode();//验证码
        string valid = "";
        System.IO.MemoryStream ms = gif.Create(out valid);
        Session["sdf"] = valid;//记忆验证码
        //清空输出
        Response.ClearContent();
        Response.ContentType = "image/png";
        Response.BinaryWrite(ms.ToArray());//以图片格式输出。
        Response.End();
    }
</script>

