Ejemplo n.º 1
0
        private void Page_Load(object sender, System.EventArgs e)
        {
            // �ڴ˴������û������Գ�ʼ��ҳ��
            int itemid = (Request.QueryString["ItemID"]==null)?0:Int32.Parse(Request.QueryString["ItemID"].ToString());
            int boardid = (Request.QueryString["BoardID"]==null)?0:Int32.Parse(Request.QueryString["BoardID"].ToString());

            BBSClass bbs = new BBSClass();
            BBSForumItem item = new BBSForumItem();

            item.ItemID = itemid;
            try
            {
                item.DelAttachment(Server.MapPath(".")+"\\Attachment\\");
                bbs.DelItem(item);
                Response.Write("<script>alert('ɾ���ɹ�');opener.location.reload();close();</script>");

            }
            catch(Exception ex)
            {
                UDS.Components.Error.Log(ex.ToString());
                Server.Transfer("../../Error.aspx");
            }
        }