| re: How can I call a form's event using a string
It work!
Thank you veru much.
On Mon, 3 Oct 2005 09:01:04 +1000, "david epsom dot com dot au"
<david@epsomdotcomdotau> wrote:
[color=blue]
>You need to change the event handler from Private
>to Public. Then:
>
>
>Set frm = forms("frmName")
>CallByName frm "procedure_name"
>
>or
>
>Run "forms('frmName').procedure_name"
>
>(but for form procedures the 'run' method will
>run the procedure twice every time you call it.)
>
>In A97, there was a way to call form procedures
>directly: Run "form_frmName.procedure_name", but that
>breaks the modern interface paradigm so it was disabled.
>
>
>(david)
>
>"BUX" <NoSpam@NoSpam.it> wrote in message
>news:ibi0k19j9kidl5lpd656sb0fc87rgshmib@4ax.com.. .[color=green]
>>I have to call Forms!myForm.myControl_AfterUpdate using
>> myString = "Forms!myForm.myControl_AfterUpdate".
>> I have tried with
>>
>> Application.Run myString
>>
>> Call myString
>>
>> eval myString
>>
>> but no one work.
>>
>> I tried also using the class module name:
>> myString= "Form_myForm.myControl_AfterUpdate"
>> but it work only if is used without quote in debug window.
>>
>> Have you any suggestion?
>> thank you
>>
>> BUX[/color]
>[/color] |