Similarly, the DataGrid class USES view state to issue pagination, edit, and sorting events.
同样地,datagrid类使用ViewState发布分页、编辑和排序事件。
If an admin event occurs (URL or button click), the admin webflow will go into the view state admin.
如果发生了一次admin事件(url或者按钮点击),那么adminwebflow将会进入到视图状态admin中。
Using nonprintable characters to delineate the objects stored in view state serves two purposes.
使用非打印字符分割 ViewState中存储的对象有两个目的。
View state can also be hashed or encrypted to prevent a user from tampering with or decoding it.
还能对ViewState进行哈希或加密,以防止用户篡改或解码。
Because you did not specify any page for this view state, by convention admin.jsp will be served to the user.
通过使用admin . jsp,因为您不能为该视图状态指定任何页面。
Second, and more importantly, it reduces the number of characters used to encode the objects in view state.
第二个,也是更重要的目的是它减少了为ViewState中的对象编码所使用的字符数量。
View state is a fancy name for ASP.NET storing some state data in a hidden input field inside the generated page.
视图状态是一个有趣的名称,用于表示在所生成页的隐藏输出字段中存储一些状态数据的ASP.NET。
If we do the same in 2.0, the size of view state is reduced to 6,728 characters, a reduction of nearly half.
如果在2.0中也这样做,ViewState大小减少到6,728个字符,几乎减少了一半。
For those of you building controls, the usage model for control state is not quite as convenient as view state.
对于您的那些生成控件,控件状态的使用模型不像ViewState一样方便。
The exception to this is that some controls also use view state for behaviors as well as plain-state retention.
例外情况是,一些控件既使用ViewState保留行为,也保留一般状态。
So it's either populating the controls, setting view state, applying themes, etc., everything happens on the page load.
因此,不是填充控件、设置viewstate、应用主题等一切都发生在页面加载上。
There is one other important place where view state is used, and that is in controls that issue server-side change events.
使用ViewState 的另一个重要之处是在控件中发布服务器端更改事件。
The stored message is retrieved from PortletSession, when the portlet is in view state, as described in the following sections.
当Portlet 处于视图状态时,可以从PortletSession检索存储的消息,如以下部分所述。
To see what happens when view state is not enabled, try adding enableviewstate='false' as an attribute on the span element.
如果想知道 ViewState 不可用时发生的事情,尝试添加enableviewstate='false'作为范围元素的一个属性。
There is also an additional overhead incurred when serializing or deserializing view state data that is posted back to the server.
对发回服务器的视图状态数据进行序列化或取消序列化时,也会发生额外的开销。
Unfortunately, if you want to use features like sorting, paging, or editing in the DataGrid, you cannot disable its view state.
遗憾的是,如果您想要使用DataGrid中诸如排序、分页或编辑的功能,则不能禁用其ViewState。
It is important to note that if the request is a postback, the values of the controls have not yet been restored from view state.
需要注意的是,如果请求需要进行回调,那么这些控件的值是不能够在viewstate中被缓存的。
With view state, developers can focus on the programming model and user interaction without having to worry about retaining state.
使用ViewState,开发人员能够专注于编程模型和用户界面,而不用担心状态保持。
Deciding when to disable view state in your controls is obviously important if you are concerned about the size of your responses.
很明显,如果您关心响应大小,那么决定何时禁用控件的ViewState是重要的。
This becomes particularly painful when you use data-bound controls, all of which use view state to save their state across postbacks.
当使用数据绑定控件时,所有控件都使用ViewState保存回发后的状态,这将变得异常痛苦。
Note that this application relies on the character encodings currently used for view state which may change before the final release.
注意,这个应用程序依赖于目前ViewState使用的编码字符,在最终版本发布前可能会改变。
When the page is posted back to the server, the server can parse, validate, and apply this view state data back to the page's tree of controls.
当该页发回服务器时,服务器可以分析、验证、并将此视图状态数据应用回该页的控件树。
Because view state retains the previous value across the request, it will start with the last value displayed and show 1, 2, 3, 4, and so on.
因为ViewState在请求期间保持以前的值,因此它将从上一次显示的值开始,显示1、2、3、4等等。
Without doing anything special, you can look forward to an immediate reduction in the size of your view state with the release of ASP.NET 2.0.
随着 ASP.NET 2.0版本的发布,您能够期望立即减小ViewState大小,而无需做任何特别的工作。
Several server controls, the most well known of which is the DataGrid, tend to make excessive use of view state, even in cases where it is not needed.
许多的服务器控件很趋于使用ViewState,如众所周知的DataGrid,而有时候是没有必须使用的。
If you are not doing postbacks in a page or are always regenerating the controls on a page on each request, you should disable view state at the page level.
如果您不发回页,或者总是针对每个请求重新生成页上的控件,则应该在页级别禁用视图状态。
In ASP.NET 2.0, cross-page Posting and server transfer offer a familiar programming model, but potentially move a significant chunk of data through the view state.
在ASP.NET 2.0中,cross - page posting和servertransfer提供了一个常见的编程模型,但却潜在地通过View State移动了大块的数据。
Before I jump into the improvements in view state in ASP.NET 2.0, a short summary of the purpose and implementation of view state in the current release is in order.
在介绍ASP.NET 2.0ViewState的改进之前,简要总结目前版本中ViewState的用途和实现是适宜的。
Before I jump into the improvements in view state in ASP.NET 2.0, a short summary of the purpose and implementation of view state in the current release is in order.
在介绍ASP.NET 2.0ViewState的改进之前,简要总结目前版本中ViewState的用途和实现是适宜的。
应用推荐