Use the `oncreate` argument.
-- Vinicius Assef On 27 October 2015 at 08:54, Serge Bourgeois <[email protected]> wrote: > > When creating a new record with smartgrid, the the 'onvalidation' > function cannot give the form.vars.id is since the record is not created > yet. > I understand that the onvalidation para allow to control what happens > before the form is accepted, but I confess I couldnt' find a kind of > 'after_validation'. > In fact, I'd like to create and insert thumbnails automatically when > creating new record. For this, I neew the id of the record, just after > creation, as for instance described at the page 145 of the book 'web2py > application development cookbook' of Marino Reingart, Pablo Martin Mulone, > Massimo Di Pierro, Bruno Cezar Rocha, ... ,in the function ' : > make_thumbnail > > Thanks in advance for any help! > > > > > > -- > Resources: > - http://web2py.com > - http://web2py.com/book (Documentation) > - http://github.com/web2py/web2py (Source code) > - https://code.google.com/p/web2py/issues/list (Report Issues) > --- > You received this message because you are subscribed to the Google Groups > "web2py-users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.

