>I know that click method does not allow embedded procedures.
>
>But is there any trick to execute a small piece of code inside the method,
>calling it with Do, or other command ?
>
>It would be very useful because when you write inside a procedure it will not work,
>if inside the procedure there are lines as thisform.command1.click, etc.
>
>
>Moises
You can create new methods on the form, which are like procedures, which allow you to call them wherever you like. Something like:
thisForm.myCustomProcedure()
And you add the code you want there, including parameters, by adding a new method to the form (Form menu -> New Method...) and then putting code there.