62,243
社区成员




<asp:ScriptManager ID="ScriptManager1" runat="server" EnablePageMethods="true">
<Services>
<asp:ServiceReference Path="../../WebServ/ContentOperServ.asmx" />
</Services>
</asp:ScriptManager>
function DeleteInfo(infoID)
{
if(confirm('确定要删除吗?'))
{
ARSSPortalSite.WebServ.ContentOperServ.DeleteInfoByID(infoID, DeleteInfoSuc);
}
}
using System;
using System.Data;
using System.Web;
using System.Collections;
using System.Web.Services;
using System.Web.Services.Protocols;
using System.ComponentModel;
using System.Web.Script.Services;
using ARSS.MOD.SUP;
using ARSS.BLL.SUP;
namespace ARSSPortalSite.WebServ
{
/// <summary>
/// ContentOperServ 的摘要说明
/// </summary>
[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
[ToolboxItem(false)]
[ScriptService]
public class ContentOperServ : System.Web.Services.WebService
{
[WebMethod]
[ScriptMethod]
public int DeleteInfoByID(int infoID)
{
ContentOperation contentOperManager = new ContentOperation();
return contentOperManager.DeleteInfoByID(infoID);
}//删除新闻
}
}
后台Load注册btnDelete
ScriptManager1.RegisterAsyncPostBackControl(btnDelete);