Read and respond to this message at: https://sourceforge.net/forum/message.php?msg_id=3342563 By: woodchuck5
hihi Henner, i like the 'list_and_single' type forms and i basically use these all the time. i have taken these templates and modified them to be 'all-in-one' functional forms (list/search, update, delete, insert). the problem is if there is an insert error, the page will be redrawn with the error message(s), but without any records at all. that is, the user may be paginating through the table records and on the fifth pagination page decide to insert a new record. however if the insert does not pass validation then the user loses their current 'position'; the page is becomes empty basically and there are no navigation buttons at all (first/previous, next/last). i found out it is because of the following DbFormTag code: if ((webEvent != null) && EventType.EVENT_DATABASE_INSERT.equals( webEvent.getType()) && (errors != null) && (errors.size() > 0) && (webEvent.getTable().getId() == getTable().getId())) { // error in insert event, nothing to do! navEvent = null; resultSetVector = null; setFooterReached(true); } because navEvent is set to null and the footer flag is set to true, this causes no table data to be displayed. on my forms, i don't use any subforms at all, so i have no child fields. all fields are from one parent table. i want to be able to re-load/re-display all the current table data (like PageReloadEvent does), even when there are insert errors. but i'm not sure what other 'flags' or conditions i can modify in the code to do this, and without breaking the current behaviour... any advice? thanks in advance! woodchuck ______________________________________________________________________ You are receiving this email because you elected to monitor this forum. To stop monitoring this forum, login to SourceForge.net and visit: https://sourceforge.net/forum/unmonitor.php?forum_id=55830 ------------------------------------------------------- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42" plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php _______________________________________________ DbForms Mailing List http://www.wap-force.net/dbforms