Jaxcent for .NET

Some Important Pointers

Accidental Postbacks!

Since the important advantage of Jaxcent is that it provides a winform-style of programming, care should be taken to avoid accidental postbacks. Any accidental postbacks will cause the existing objects to be lost, and new objects to be loaded, which somewhat negates the advantages of Jaxcent!

Accidental postbacks will also cause much confusion in the debugger, because suddenly the data being looked at will be gone, and will be replaced by new data (much like what would happen in an ASP.NET project without Jaxcent.)

Therefore - unless you are adding Jaxcent in an ad-hoc manner to an existing ASPX project for handling particular event(s) - postbacks should be disabled in Jaxcent.

Submits without an ACTION do cause PostBacks, and such PostBacks should be disabled by adding the code onSubmit="return false;" in all the FORM tags, e.g.


    <FORM onSubmit="return false;">

This should be done on all FORMS being used in Jaxcent. The only exception are FORMS that are being used to upload files. (For uploading files, see the sample project for File Uploading.) In these cases, the SUBMIT action is required to upload the file, and Jaxcent handles this case appropriately (without involving a PostBack.)

All INPUT fields should be placed inside such forms - while Jaxcent doesn't actually need FORMs, some browsers will not show INPUT fields if they are not inside FORM tags.

Working with .ASPX

Jaxcent does not require .ASPX, and can work with plain HTML files.

But it does integrate well with .ASPX files.

It is important to remember that while Jaxcent is aware of .ASPX, the reverse is not true. In particular, when Jaxcent events are being processed, at that time the page object has finished its lifecycle as far as as .ASPX is concerned. Therefore the Response object can no longer be used to do things like re-direct to a different page or set session data, or anything which requires the .ASPX to do a post-back.

Instead, these tasks must be done in a Jaxcent way. Instead of Response.Redirect, the Navigate method from the JaxcentPage class should be called to cause the browser to navigate to a different URL. Cookies should be set using the JaxcentPage.SetCookie method instead of via the Response object.

Instead of the .ASPX session, Jaxcent provides its own session for maintaining user data across multiple pages, which should be used.

Useful Areas to Check

In addition to the Getting Started overviews for C# or VB, it is recommended that the following be reviewed:

Known Problems

Also see Known Problems in Jaxcent.