在我看来,你能做的有点奇怪..Page.ClientScript.RegisterStartupScript(this.GetType(),"KeyName","alert('changedmymind')",true);然后您无法取消注册或停止以编程方式呈现javascript。微软为什么要这样做?我不喜欢这里的工作..http://hemant-vikram.blogspot.com/2005/11/unregister-startup-script-workaround.html而且我不喜欢只重新注册它而让它什么都不做的选项..想法? 最佳答案