This sample demonstrates using the wwMethodCallback control to call methods of the current page. To use this control all you do is drop it on the page and the control then exposes each server method of the page (or user or server control) marked with the [CallbackMethod] attribute and makes it accessible via a proxy object. The proxy is a global object in JavaScript that has the same name as the callback control and exposes all of the methods marked with the [CallbackMethod] attribute. This example demonstrates passing complex objects. Here a DataTable, a simple Entity object, a complex entity object (with subitems and an sub-collection) are passed to the client. Objects on the client can be accessed with standard object syntax so you still use Customer.Company for objects. DataTables are presented as an array of objects, so Rows can be accessed as Table.Rows[x].Company. Objects can also be passed back to the server, so you can download an object, modify it then send it back to the server. The wwMethodCallback control supports two-way JSON marshalling. The first example returns a simple DataTable and loads up the list with the result values by looping throught he rows and using the DOM to create list items. The second example returns a complex object from the server. The object contains a child object (PhoneNumbers) and an array of Order objects which are returned only if the Return Order Entries checkbox is checked. The object is passed from the server to the client where the values are displayed in the textboxes. You can change values and then Update the object, which sends the updated values that are stored back into the object to the server. The client side object is JSON encoded and sent back to the server. The server then merely echos the values back as a string. If you changed the values in the fields you should see those values returned from the server. Note also that exception handling carries exception to an error handler that can be specified as the last parameter of a callback method. A server side exception is picked up and returned to the client as a simplified object that contains the error message. You can easily route the error handler to a single page function or use specific error handlers if generic operation is not adequate.