更新到 Visual Studio 2010 Service Pack 1 后无法加载视图状态错误
更新到 Visual Studio Service 2010 Pack 1 后,我在所有 Web 表单上加载视图状态时收到错误消息。
错误消息:
加载视图状态失败。视图状态所在的控制树 正在加载的控制树必须与用于保存的控制树相匹配 上一个请求期间的视图状态。例如,当添加 动态控制,回发期间添加的控件必须匹配 初始期间添加的控件的类型和位置 请求。
升级之前一切正常。
编辑:
问题实际上是由于我在 .我删除了头上的 runat 服务器,解决了问题
I am receiving an error loading viewstate on all my webforms after updating to Visual Studio Service 2010 Pack 1.
Error message:
Failed to load viewstate. The control tree into which viewstate is
being loaded must match the control tree that was used to save
viewstate during the previous request. For example, when adding
controls dynamically, the controls added during a post-back must match
the type and position of the controls added during the initial
request.
Everything was working fine before the upgrade.
Edits:
The problem was actually due to jQuery libaries from google I referenced on my . I removed the runat server on the head, that fixed the problem
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我通过删除母版页上的 runat="server" 解决了该问题。这解决了问题。母版页头有一些对 Google jQuery 文件的引用。
I fixed the problem by removing runat="server" on my master page. That fixed the problem. Masterpage head has some references to Google jQuery files.