This function is the first verion of JAS DynamicScreen functionality. Although to date it's been working great, we intend to make a newer version that is broken up into smaller modules and is not user interface specific as much, at least so the same code can be used to make screens using various user interfaces.
Note that this function is responsible for both displaying custom screens, editting data and viewing query results, as well as screen editting. The screen editting works in a WYSIWYG fashion. You Need ADMIN permissions to modify the Screens in JAS at this time. Eventually this will be a specific Permission that is appropriately named so you do not need to specifically be a system administrator to customize screens.
You can call up a screen and inadvertanly use this function by calling either: http://jas/?SCREENID=(SCREENID) or ?Screen=NameHEre Where screenid is the UID of the SCREEN you wish to view. If you call up a DETAIL screen in this manner without passing also the UID parameter for the record you wish to view/edit, clicking the save button will fail: no assumption is made that adding a record in this circumstance is desired. If you want to add a new record, try: // http://jas/?SCREENID=1&UID=0
You can call up screens by name as well: http://jas/?screen=jaddress%20Search
If you have the correct user permission, you will see a edit mode checkbox that will place the screen into edit mode so you can customize it as you see fit.