ACC: DoEvents, SendKeys May Not Be Supported in UDFs
ID: Q89592
|
The information in this article applies to:
-
Microsoft Access versions 1.0, 1.1, 2.0, 7.0, 97
SUMMARY
Moderate: Requires basic macro, coding, and interoperability skills.
Under certain circumstances, DoEvents and SendKeys are not supported when
called by user-defined (custom) functions in Visual Basic for Applications
(or Access Basic in versions 1.x and 2.0).
MORE INFORMATION
DoEvents and SendKeys are not supported in user-defined functions in the
following situations:
- When calculating a field in a query.
- When calculating a control on a form or report.
- From a Visual Basic (or Access Basic) Fill function for a list box,
combo box, or OLE Object field.
The DoEvents statement will not allow messages to be processed in
these circumstances; instead, it will immediately return. Thus, any
keys sent through SendKeys statements or functions will not be
processed until all the computations listed above have been completed
and responses have been returned to the user.
REFERENCES
For more information about DoEvents, search the Help Index for "DoEvents."
For more information about SendKeys, search the Help Index for "SendKeys
Statement."
Additional query words:
udf
Keywords : kbprg PgmErr
Version : 1.0 1.1 2.0 7.0 97
Platform : WINDOWS
Issue type : kbinfo