ACC97: "Convert Macros to Visual Basic" Converts Incorrectly (167061)
The information in this article applies to:
This article was previously published under Q167061 Moderate: Requires basic macro, coding, and interoperability skills.
SYMPTOMS
When you run the "Convert Macros to Visual Basic" command on a macro that
has any of the following RunCommand actions
RunCommand ArrangeIconsByCreated
RunCommand ArrangeIconsByModified
RunCommand ArrangeIconsByName
RunCommand ArrangeIconsByType
RunCommand StepInto
RunCommand FindNext
RunCommand HyperlinkDisplayText
the macro actions are converted to the following methods of the DoCmd
object in the module
DoCmd.RunCommand acCmdSortByCreated (ArrangeIconsByCreated)
DoCmd.RunCommand acCmdSortByModified (ArrangeIconsByModified)
DoCmd.RunCommand acCmdSortByName (ArrangeIconsByName)
DoCmd.RunCommand acCmdSortByType (ArrangeIconsByType)
DoCmd.RunCommand <blank> (StepInto)
DoCmd.RunCommand <blank> (FindNext)
DoCmd.RunCommand acCmdEnterEditMode (HyperlinkDisplayText)
and you receive the following compile error when you try to compile the
module:
Compile error
Variable not defined.
CAUSE
The "Convert Macros to Visual Basic" command on the Macro submenu,
incorrectly converts the macro actions.
RESOLUTION
You must manually change the syntax for the RunCommand actions in the
module.
REFERENCES
For more information about converting macros, search the Help Index for
"macros, converting," and then "convert macros to Visual Basic," or ask the
Microsoft Access 97 Office Assistant.
Modification Type: | Major | Last Reviewed: | 9/26/2003 |
---|
Keywords: | kberrmsg kbprb KB167061 |
---|
|