See the use of form.setBookmark() in the v2 API. It allows you to reacquire your bizData each time the form is redisplayed.

Chris

Mark Lundquist wrote:

OK Cocooners, here is the deal.

I'm porting a woo... er, CForms form from 2.1.3 to 2.1.4. Before, without <wd:action> I had to emulate that myself. I hacked my own showForm() that checked the request to figure out which button was pressed, and it only invoked validation if a particular one of the form buttons was pressed (the "Update" button, which conceptually is the real "submit" control, i.e. whose intent is to finalize the form processing).

So I thought I'd switch to using action and submit widgets in 2.1.4. But there's a problem.

In my hacked-over showForm(), if the form was submitted by something other than the "Update" button, I not only bypassed validation, but I exited showForm()'s loop and returned. That took me back to the "outer loop" in my flow that checked the request to find out which button was pressed. This was essential, because some of the other buttons do things that affect the display of the page. So redisplaying the form entailed a new invocation of sendPageAndWait() in the next iteration of the loop, with potentially different bizdata.

When I switched to <wd:action>, this broke... my event handlers fired, so the model has changed, but I'm stuck in showForm()'s loop with stale bizdata until showForm() decides that form processing is finished (i.e., validation succeeded).

Can someone tell me how do I fix this?

Thanks,
Mark


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to