Script
$.ajax({
type: "post",
url: "Index.aspx?cmd=SettingCreateMember",
success: parseXml
});
Code in MasterPage_pagrLoad()
if (Req开发者_Go百科uest["cmd"] == "SettingCreateMember")
{
var doc = XDocument.Load(Server.MapPath(".") + "\\Administrator\\Questions.config");
Response.Write(doc);
Response.End(); //this line error:Unable to evaluate expression because the code is optimized or a native frame is on top of the call stack
}
inline response.end() error say:Unable to evaluate expression because the code is optimized or a native frame is on top of the call stack why?
Response.End uses a ThreadAbortException to end execution of the page and flush the buffer to the client (MSDN). Response.Flush() will not generate a ThreadAbortException.
精彩评论