Copy event procedure

I

Igor G.

I must copy On Got Focus event procedure to many datasheet fields.
Can I do this automaticaly to all, or one by one datasheet, or I must use
nerve pills before starting copy. :)
Thanks!
 
J

Jeff L

Is the code that you're copying going to be the same for each field?
Perhaps this is something that you could accomplish via a procedure
call or function?
 
I

Igor G.

This is the same code for all fields in many datasheets.
With this code, I call procedure to display data with SYSCMD method to
status bar text.
 
K

Klatuu

Write a Public Function in a standard module that does what you want it to
do. It will need to have a parameter or parameters so it will know what to
do it with.

Then, you won't need to put any VBA code in the datasheet form's modules.
just put a call to the function in the Got Focus event text box in the
controls' property dialog:

=FunctionName(SomeValue)
 
Top