Callback and client-side paging support – PB Docs 126

Callback and client-side paging support

The PagingMethod property enables you to specify how paging
requests are handled. The default setting is PostBack, which posts
each page request back to the server. You can change the setting
on the Web Generation page in the Properties view with the Format
to Configure set to HTML/XHTML.


CallBack paging uses
a script callback feature to provide page navigation without posting
the whole page back to the server. The XML data for the next requested
page is downloaded as an XML string returned to the callback. A JavaScript
function on the client collects the data and invokes the client-side XSLT
processor to transform the data using the XSLT stylesheet that was downloaded
and cached on the first request. The next page of data is displayed on
demand. If you set the PagingMethod property to CallBack, you do
not need to write server-side code and client-side JavaScript to
take advantage of the script callback feature.

For the XML rendering format, the design of the Callback!
option requires that a reusable XSLT stylesheet be generated so
that the browser can cache it. The benefit from this requirement
is that only the XML data for the next requested page need be returned
by the callback. This XML data is always trivial in size (about
a 1 to 20 ratio), resulting in significant bandwidth savings. This
is unlike other implementations, where the entire presentation is
always regenerated and downloaded again from every callback.The
generated XSLT stylesheet is not reusable, and therefore cannot
be cached by the browser, if the DataWindow layout is inconsistent
page-to-page, or it does not contain a complete first page of data.
In these scenarios, the Callback! option defers to PostBack! until
a stylesheet can be generated that is reusable, and can therefore
be cached in the browser.


When the PagingMethod property is set to XMLClientSide, the
page takes slightly longer to load on the first request because
all the data in the result set is pulled down to the client, but
subsequent paging requests take place entirely on the client. InsertRow, AppendRow,
and DeleteRow actions take place on the client
with no postback or callback to the server. However, any computed
fields in the DataWindow that rely on the RowCount method
are not reevaluated until the user performs an action such as an Update or Retrieve that
forces a postback to the server.

Client-side paging is available only for the XML rendering
format and in button actions and client JavaScript paging functions
of the Web DataWindow client control.

Document get from Powerbuilder help
Thank you for watching.
Was this article helpful?
Notify of
Inline Feedbacks
View all comments
Would love your thoughts, please comment.x