开发中遇到令人蛋疼的问题:
只能在执行Render()的过程中调用RegisterForEventValidation
当出现的异常的提示:
异常详细信息: System.InvalidOperationException:只能在执行Render()的过程中调用RegisterForEventValidation;
不要伤心,下面是解决办法:
出现这个异常,解决问题只需要在<%@ Page %> 指令中加上 EnableEventValidation="false"