Hi,
One of the new features not documented in the RC10 release topic is the ability to requery a record. This might be handy if you have other applications besides Servoy updating your database and you want to be sure your user is looking at the correct info.
I've created a method that you can store as a Global Method and then, for example, attach to a button of ANY form, or use in other methods. It refreshes the data directly displayed on your form (not portals or tabpanels).
for ( var i = 0 ; i <= eval("forms."+currentcontroller.getName(
+".controller.getMaxRecordIndex()") ; i++ )
{
databaseManager.refreshRecordFromDatabase(eval
("forms."+currentcontroller.getName()+".foundset"),i)
}
Basically, this method loops through all records in the foundset and by using the currentcontroller.getName() function, it can be used on any form.
Hope this inspires people to do cool stuff....
Paul